Skip to content

Instantly share code, notes, and snippets.

@chris-lovejoy
Created May 1, 2020 12:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save chris-lovejoy/22c73bc4e87f223878f83cdbc8463c1a to your computer and use it in GitHub Desktop.
Save chris-lovejoy/22c73bc4e87f223878f83cdbc8463c1a to your computer and use it in GitHub Desktop.
Creating lists for each job characteristic
cols = []
extracted_info = []
if 'titles' in desired_characs:
titles = []
cols.append('titles')
for job_elem in job_elems:
titles.append(extract_job_title_indeed(job_elem))
extracted_info.append(titles)
if 'companies' in desired_characs:
companies = []
cols.append('companies')
for job_elem in job_elems:
companies.append(extract_company_indeed(job_elem))
extracted_info.append(companies)
if 'links' in desired_characs:
links = []
cols.append('links')
for job_elem in job_elems:
links.append(extract_link_indeed(job_elem))
extracted_info.append(links)
if 'date_listed' in desired_characs:
dates = []
cols.append('date_listed')
for job_elem in job_elems:
dates.append(extract_date_indeed(job_elem))
extracted_info.append(dates)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment