Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We could cobble some stuff from here #13

Open
weaverbel opened this issue Jun 2, 2017 · 12 comments
Open

We could cobble some stuff from here #13

weaverbel opened this issue Jun 2, 2017 · 12 comments

Comments

@weaverbel
Copy link
Contributor

This is from the PYCAR Python course for journalists - from @elainewong
https://github.com/ireapps/pycar

Good basics for us to 'borrow', @richyvk @prcollingwood ?

@richyvk
Copy link
Collaborator

richyvk commented Jun 2, 2017

Def worth a look. might be some 'examples' we can use. I think we have the programming concepts pretty well covered though we what we've got.

@prcollingwood
Copy link
Contributor

I think that for the purpose of getting librarians interested in learning more about Python, a shorter basics section like in Elaine's lesson is better. The standard software carpentry lesson spends the whole day on it without showing you why you might want to use Python. Elaine's suggestion of adding a CSV component is good as this shows you something useful you can do with Python.

@elliewix
Copy link
Contributor

elliewix commented Jun 2, 2017

I've taught python to LIS masters students for two semesters now, and here are some of the tasks that seem to resonate with them (and things I've done myself):

  • parsing XML files to create new data
  • comparing two sets of data (e.g. comparing a list of ISBNs to a new list and reporting what is new, missing, duplicated, etc.)
  • parsing a plain text file and filtering out lines based on a test (e.g. look through a list of bibliographic entries and flag the ones with malformed dewey entries)
  • parsing through a full text book and splitting all the chapters out into separate files
  • extracting all the hrefs from a table in a webpage
  • using regex to extract data points from a semi-structured text file to create a structured data set

@jt14den
Copy link
Member

jt14den commented Jun 2, 2017

@elliewix I like your tasks list. Do you have the data you've used for these?

@elliewix
Copy link
Contributor

elliewix commented Jun 2, 2017

@laufers
Copy link
Contributor

laufers commented Jun 2, 2017

The URL parsing is a web-scraping exercise using Beautiful Soup or if the example you mentioned that the urls in a HTML Table structure, using Pandas. Maybe this task gets forwarded to the WebScraping folks? ex: http://ouinformatics.github.io/swc_beautiful_soup/

@elliewix
Copy link
Contributor

elliewix commented Jun 2, 2017

They already have the task of getting all URLs in there (In [13]). that's a pretty classic example task for all web scraping thing.

@richyvk
Copy link
Collaborator

richyvk commented Jun 6, 2017

@elliewix Like that list of tasks a lot. At least some can be done without external libraries which is good. All probably, but with more code needed.

Anyway, I think we have enough examples there to use throughout the lesson.

@harshmangal
Copy link

@elliewix how to parse data into separate chapters?

@elliewix
Copy link
Contributor

I'm writing a smaller example of this now for my class, which could be more manageable than a full book.

@harshmangal
Copy link

ok. would you add that one to your github repositories?

@elliewix
Copy link
Contributor

I have an in-progress version on the lesson here: https://github.com/elliewix/IS-452-Fall2017/blob/master/Lectures/Week09-While%26sentinelloops.ipynb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants