Get the Producer Price Index (PPI) for a variety of countries over time from the OECD. The PPI measures the average change over time in the prices received by domestic producers (manufacturing) for their output. Because producers tend to pass rising input costs on to their customers with a lag, the PPI is generally seen as a leading, upstream indicator of cost pressure that later shows up in the Consumer Price Index (CPI).

The index covers manufacturing output only, is not seasonally adjusted, and is set to 100 in the base year, which can vary per country.

The OECD stopped updating this series in its Key Economic Indicators dataset during 2023: annual values end in 2022, and monthly and quarterly values end in early 2023 for all but a couple of countries. A start_date after that point returns an empty DataFrame.

See definition: https://www.oecd.org/en/data/indicators/producer-prices-ppi.html

Also known as: PPI, wholesale prices, factory gate prices, upstream inflation.

Producer Price Index in Python or via the MCP

Install the Finance Toolkit with:

pip install financetoolkit -U

Then call get_producer_price_index as shown below.

from financetoolkit import Economics

economics = Economics(start_date='2018-01-01', end_date='2022-01-01')

economics.get_producer_price_index(
    countries=['United States', 'Germany'],
    period='yearly'
)

Or, after setting up the Finance Toolkit MCP, ask:

How did producer prices in the United States and Germany develop each year from 2018 to 2022?

Which returns:

  United States Germany
2018 106.059 102.758
2019 106.067 103.65
2020 103.849 103.15
2021 116.511 108.242
2022 134.46 122.75

Parameters

get_producer_price_index accepts the following parameters.

ParameterTypeDescriptionExample
countrieslist[str] | str | NoneThe countries to include in the data. Defaults to None.["United States", "Germany"]
periodstr | NoneWhether to return the monthly, quarterly or the annual data. Defaults to None, which is quarterly when the Economics class was initialized with quarterly=True and monthly otherwise."quarterly"
rollingintThe rolling window size to use for smoothing the data (simple moving average). Defaults to None.4
trailingintThe trailing window size to use for summing the data over trailing periods (e.g. a trailing-4-quarter sum). Defaults to None.4
growthboolWhether to return the growth data or the actual data. Defaults to False.True
lagintThe number of periods to lag the data by. Defaults to 1.4
standardizeboolWhether to standardize (Z-Score) the result. When combined with growth=True, standardizes the growth values instead of the raw values. Defaults to False.True
roundingint | NoneThe number of decimals to round the results to. Defaults to None.2
Share