Add BLS client library, example scripts, and usage docs
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
36
bls_client/queries/productivity.py
Normal file
36
bls_client/queries/productivity.py
Normal file
@ -0,0 +1,36 @@
|
||||
"""
|
||||
Pre-built productivity series IDs — Major Sector Productivity & Costs.
|
||||
"""
|
||||
|
||||
from ..series import productivity
|
||||
|
||||
def business_output_per_hour(seasonal: bool = True) -> str:
|
||||
"""Business sector output per hour worked (quarterly)."""
|
||||
return productivity("business", "output_per_hour", seasonal)
|
||||
|
||||
|
||||
def business_unit_labor_cost(seasonal: bool = True) -> str:
|
||||
"""Business sector unit labor costs (quarterly)."""
|
||||
return productivity("business", "unit_labor_cost", seasonal)
|
||||
|
||||
|
||||
def business_real_comp_per_hour(seasonal: bool = True) -> str:
|
||||
"""Business sector real compensation per hour."""
|
||||
return productivity("business", "real_comp_per_hr", seasonal)
|
||||
|
||||
|
||||
def nonfarm_output_per_hour(seasonal: bool = True) -> str:
|
||||
return productivity("nonfarm_business", "output_per_hour", seasonal)
|
||||
|
||||
|
||||
def manufacturing_output_per_hour(seasonal: bool = True) -> str:
|
||||
return productivity("manufacturing", "output_per_hour", seasonal)
|
||||
|
||||
|
||||
def productivity_dashboard() -> dict:
|
||||
return {
|
||||
"Business Output/Hr": business_output_per_hour(),
|
||||
"Business Unit Labor Cost": business_unit_labor_cost(),
|
||||
"Nonfarm Output/Hr": nonfarm_output_per_hour(),
|
||||
"Manufacturing Output/Hr": manufacturing_output_per_hour(),
|
||||
}
|
||||
Reference in New Issue
Block a user