The Kevin Bacon files

I realized I forgot to show you something in class, so I created a new gist to show it.

It is kbacon4.txt, which is the file saved by — the fourth version of the script we went over in class when talking about regex (the four scripts are in another gist). This text file is the final list of local links scraped off the Kevin Bacon Wikipedia page.

  • ➞ kbacon1.txt (781 lines)
  • ➞ kbacon2.txt (681 lines)
  • ➞ kbacon3.txt (451 lines)
  • ➞ kbacon4.txt (400 lines)

The point is that by refining, first, the “find” parameters, and second, the regex string, we match fewer and fewer links, and eventually we get the set of only the links we want to crawl.

Scan the list of 400 links to see that they are all links to Wikipedia pages, although there might still be some links that we would like to eliminate — depending on WHY we are collecting these links.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s