Browse files

added README and update module docs for webscraping tutorials

  • Loading branch information...
1 parent 1d8a3d9 commit 203b084464a7aab30ddf4eb37254808e8b704012 Serdar Tumgoren committed Jan 26, 2012
View
4 tutorials/webscraping101/README
@@ -0,0 +1,4 @@
+This directory contains scripts that demonstrate basic Python in a web-scraping context.
+
+1) failed_banks_scrape.py - download and parse a single Web page
+2) fec_efiles_scrape.py - make a POST request to fetch download links for campaign finance reports
View
8 tutorials/webscraping101/failed_banks_scrape.py
@@ -1,9 +1,8 @@
#!/usr/bin/env python
"""
-This is the first example scrape in our series.
-
-In this scrape, we'll demonstrate some Python basics
-using the FDIC's Failed Banks List.
+This scrape demonstrates some Python basics using the FDIC's Failed Banks List.
+It downloads a single web page and shows how to use a 3rd-party library
+to extract data from the HTML.
USAGE:
@@ -12,7 +11,6 @@
python failed_banks_scrape.py
-
NOTE:
The original FDIC data is located at the below URL:
View
11 tutorials/webscraping101/fec_efiles_scrape.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python
"""
-The third scrape in our series demonstrates how to "fill out" an
+This scrape demonstrates how to "fill out" an
online form to fetch data from a remote server.
More accurately, we'll show how to make a POST request to
@@ -14,7 +14,16 @@
http://fec.gov/finance/disclosure/efile_search.shtml
+USAGE:
+
+You can run this scrape by going to command line, navigating to the
+directory containing this script, and typing the below command:
+
+ python fec_efiles_scrape.py
+
+
HELPFUL LINKS:
+
Python Modules used in this script:
* BeautifulSoup: http://www.crummy.com/software/BeautifulSoup/documentation.html
* CSV: http://docs.python.org/library/csv.html

0 comments on commit 203b084

Please sign in to comment.