wheat_data
Get ERS wheat data - the Wheat Yearbook supply, use, price, and trade tables, each pivoted to a wide layout by year.
Examples
from openbb import obb
obb.usda.wheat_data(provider='usda')
# Get world and U.S. wheat supply and disappearance since 2010.
obb.usda.wheat_data(table='world_supply_and_disappearance', start_year=2010, provider='usda')
# Get the historical by-class quarterly balance sheet.
obb.usda.wheat_data(table='by_class_quarterly', provider='usda')
Parameters
- standard
- usda
table: str | None
Default: us_supply_and_disappearance
Description
Wheat-data table to retrieve. Each table is a set of named balance-sheet, price, or trade series indexed by year and period; the series become the wide value columns while any varying wheat class, destination, market, product, or unit is folded into the pinned period label. Valid tables are:
wheat_acreage_production_yield_price, rye_acreage_production_yield_price, world_supply_and_disappearance, us_supply_and_disappearance, rye_supply_and_disappearance, food_use, government_and_private_stocks, domestic_and_international_prices, export_import_trade_by_component, all_wheat_destination_exports, by_class_inspections, exports_by_government_program, flour_production_and_disappearance, wheat_flour_price_relationships, by_class_trade_data, by_class_quarterly
start_year: int | None
Start year for filtering the data, compared against the first four digits of the marketing, calendar, or fiscal year. If None, returns from the beginning of the series.
end_year: int | None
End year for filtering the data, compared against the first four digits of the marketing, calendar, or fiscal year. If None, returns up to the most recent year.
Returns
results: WheatData
Serializable results.
provider: str | None
Provider name.
warnings: Optional[list[Warning_]]
List of warnings.
chart: Optional[Chart]
Chart object.
extra: dict[str, Any]
Extra info.
Data
- standard
- usda
period: str
Row label of the observation: the marketing, calendar, or fiscal year and its within-year period ('2024/25 MY Jun-May', '1989/90 Apr'), with any varying wheat class, destination, market, product, or unit prefixed so each row is uniquely labeled.