econpy.org

Python for Economists

Import the modules for this tutorial

This tutorial will walk you through a set of steps intended to teach you the basics of scraping data from websites. To start, enter the lines on the right into the terminal below, which will load the Python modules that'll be used in this tutorial. When you have that done, click the "Next" button above the terminal to continue the tutorial.

import requests
from BeautifulSoup import BeautifulSoup as bs