Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Downloading Industry Level QCEW Employment Data #33

Open
PFurst2000 opened this issue Nov 3, 2021 · 1 comment
Open

Downloading Industry Level QCEW Employment Data #33

PFurst2000 opened this issue Nov 3, 2021 · 1 comment

Comments

@PFurst2000
Copy link

Is it possible to download industry level QCEW data from the BLS API? I am able to download QCEW employment data for total industries and total private sector employment but when I try to download industry0specific data I receive an error that no data is available for that series.
Thanks!

QCEW_TotEmp_AllIND = bls.get_series('ENU3605310010') #works fine
QCEW_TotEmp_Priv_21 = bls.get_series('ENU3605310555') #No Data Available for Series

Error Msg:
No Data Available for Series ENU3605310555 Year: 2002
No Data Available for Series ENU3605310555 Year: 2003
No Data Available for Series ENU3605310555 Year: 2004
No Data Available for Series ENU3605310555 Year: 2005
No Data Available for Series ENU3605310555 Year: 2006
No Data Available for Series ENU3605310555 Year: 2007
No Data Available for Series ENU3605310555 Year: 2008
No Data Available for Series ENU3605310555 Year: 2009
No Data Available for Series ENU3605310555 Year: 2010
No Data Available for Series ENU3605310555 Year: 2011
No Data Available for Series ENU3605310555 Year: 2012
No Data Available for Series ENU3605310555 Year: 2013
No Data Available for Series ENU3605310555 Year: 2014
No Data Available for Series ENU3605310555 Year: 2015
No Data Available for Series ENU3605310555 Year: 2016
No Data Available for Series ENU3605310555 Year: 2017
No Data Available for Series ENU3605310555 Year: 2018
No Data Available for Series ENU3605310555 Year: 2019
No Data Available for Series ENU3605310555 Year: 2020
No Data Available for Series ENU3605310555 Year: 2021

@PFurst2000
Copy link
Author

I think my issue is similar to ticket #21 concerning downloading only annual data. Would you please provide a sample script for collecting annual data only and ignoring errors? I would hope to have this query run where null or n/a values do not halt the running of the script and are identified in the output data. For the below script I confirmed that the data is available for the county in question (Madison, NY) for the industry levels requested. However, running it produces the following error: TypeError: get_series() got an unexpected keyword argument 'annualaverages'

Thank you,

from functools import reduce
import pandas as pd
import matplotlib as plt
import numpy as np
import bls
bls.get_series(["ENU3605310531-33", "ENU3605310542"], annualaverages=True, errors="ignore")
Test = bls.get_series('ENU3605310531-33', annualaverages=True, errors="ignore")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant