Skip to content

Instantly share code, notes, and snippets.

@srang992
Created October 15, 2022 16:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save srang992/fbe973633e6bf1c8e945063217df56ad to your computer and use it in GitHub Desktop.
Save srang992/fbe973633e6bf1c8e945063217df56ad to your computer and use it in GitHub Desktop.
r = requests.get("https://www23.statcan.gc.ca/imdb/p3VD.pl?Function=getVD&TVD=53971")
bs = soup(r.content, 'html')
table = bs.find_all('table')[0]
df = pd.read_html(str(table),header=0)[0]
df
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment