OPEN-SOURCE SCRIPT

G10 Excess Liquidity Leading Indicator (Proxy)

648
█ OVERVIEW

This indicator plots a GDP-weighted composite of real money growth across ten G10 economies, measured as the deviation of each economy's annual real money growth from its own trailing trend, in a separate pane. The thesis it expresses is the excess-liquidity idea: when real money across the major economies is growing faster than its recent trend, the liquidity backdrop for risk assets is supportive, and when it is growing below trend the backdrop is restrictive. An optional SPX YoY reference line is provided on a shared scale so the user can inspect the visual relationship between the two series.


═════════════════════════════════════════════════════════════

█ HISTORY / BACKGROUND

The term excess liquidity comes from monetarist macro analysis, where the quantity of money in circulation is compared against the economy's transactional needs. The level analogue is the Marshallian K, the ratio of broad money to nominal output. The flow version used here treats the growth of real money relative to its own recent trend as a measure of surplus or deficit liquidity, on the reasoning that money created beyond what current activity absorbs tends to find its way into financial assets, while a deficit withdraws that support.

Aggregated, multi-country versions of this measure are produced by several research firms and data vendors as proprietary series, and are commonly charted against equity returns with a forward displacement to illustrate a hypothesized lead. Those vendor series are closed: their exact money aggregates, weighting, smoothing, and detrending are not published. This script is a transparent reconstruction of the concept from public data. It is not a copy of any vendor series, and its construction choices are the author's own, stated in full below.


═════════════════════════════════════════════════════════════

█ HOW IT WORKS

The script computes everything from external data requests and does not use the chart symbol's price, so its output is the same regardless of which symbol the chart shows. The pane location follows the chart; the values do not.

For each of ten economic units (United States, Euro area, Japan, United Kingdom, Canada, Switzerland, Australia, New Zealand, Sweden, Norway) the algorithm proceeds as follows.

1. It requests a money-supply series and a consumer price index from the ECONOMICS provider at monthly resolution. Requests use no lookahead and forward-fill gaps, and invalid symbols are tolerated rather than throwing.

2. It forms real money as the money-supply level divided by the CPI index.

3. It computes annual real money growth as the twelve-month percentage change of that real money series.

4. It detrends that growth by subtracting its own simple moving average over the Trend window length. The result is each economy's excess-liquidity reading in percentage points relative to its own trend.

The ten readings are then combined.

5. The composite is the GDP-weighted mean of the per-economy readings, using fixed nominal-GDP weights held as constants. Any economy whose data does not resolve returns na, is excluded from both the weighted sum and the weight total, and the remaining weights are renormalized automatically over the live subset.

6. The composite is optionally standardized by subtracting its moving average and dividing by its standard deviation over the Z-score window. If the standard deviation is zero the standardized value is na.

7. The same twelve-month-change and optional standardization are applied to SPX to produce the reference line.

The plotted objects are: the composite, drawn with a forward bar offset and colored red when below zero and blue when at or above zero; the SPX reference line in black, shown only when its toggle is on; a dashed zero line; a status table in the top right listing each economic leg as OK or missing with a live-leg count; and a warning label that appears on the last bar only when the chart is not on a monthly resolution.


═════════════════════════════════════════════════════════════

█ HOW TO USE

Apply the script on a monthly chart. The twelve-month change is computed as a twelve-bar change and the forward displacement is expressed in bars, so both only carry their intended meaning of twelve months and the configured number of months when one bar equals one month. On any other resolution the windows no longer correspond to those spans, and the script draws a label warning of this on the last bar.

Read the composite against the zero line. A blue reading means aggregate G10 real money growth is running above its own trailing trend; a red reading means it is running below trend. When standardization is enabled the vertical units are standard deviations from the windowed mean rather than raw percentage points.

The composite is displaced forward by the Forward push setting to align it visually with the period the excess-liquidity hypothesis associates it with. This displacement is a charting offset for inspection, not a forecast, and the displaced portion extending past the last bar carries no data claim.

The black SPX reference line is supplied only for visual comparison of timing on a common scale. The script does not combine the two series into a single signal.

Before interpreting the composite, check the status table. A reduced live-leg count changes which economies are present in the GDP weighting and therefore changes the composite. Because the standardization and trend windows require history, the composite is blank until enough monthly history has accumulated for the latest-starting live leg, so early chart history may show no line.


═════════════════════════════════════════════════════════════

█ SETTINGS

Trend window (months): length of the moving average subtracted from each economy's annual real money growth to form its excess reading. Default 36, minimum 12.

Z-score window (months): lookback used for the mean and standard deviation when standardizing both the composite and the SPX reference. Default 120, minimum 24.

Z-score series for comparability: when enabled, the composite and the SPX line are standardized to a common unitless scale. When disabled, the composite is shown in percentage-point deviation units and the SPX line as a raw annual percentage change. Default enabled.

Overlay SPX YoY: toggles the black SPX reference line. Default enabled.

Forward push (months / bars): number of bars by which the composite plot is shifted forward. Default 6, minimum 0, maximum 24.


═════════════════════════════════════════════════════════════

█ WHAT MAKES IT ORIGINAL

The script is a self-contained, fully on-chart reconstruction of the excess-liquidity concept rather than a wrapper around a published series. Its specific construction is: per-economy real money defined as a national money aggregate deflated by that country's CPI; annual growth of that real money detrended against its own moving average so each economy is measured relative to its own history; a GDP-weighted aggregation across ten G10 economies; and automatic renormalization of the weights over whatever data legs resolve at runtime, with a coverage table that makes the live universe and each economy's contribution status visible on the chart. A configurable forward displacement and an optional shared-scale SPX reference are included so the timing relationship can be inspected directly.

The money aggregates are each economy's most-available headline measure from the data provider and are therefore a mixed family across countries by design; each leg is internally consistent through time, which is what the annual-change and detrending steps require. The aggregate definition, the choice of detrending against a trailing trend, the weighting, and the windows are modeling choices made by the author and are exposed as inputs or as clearly marked constants, not hidden internals.


═════════════════════════════════════════════════════════════

█ NOTES / LIMITATIONS

Monthly resolution only. The twelve-month change and the forward offset are bar-based. On non-monthly charts they no longer correspond to twelve months and the configured number of months. The script flags this with a label on the last bar.

Forward displacement. The composite is shifted forward by the offset using the plot offset. The displaced segment extends beyond the last historical bar and moves as new bars arrive. It is a visual offset and not a prediction.

Data dependence and coverage. The composite is built entirely from external money-supply and CPI series for ten economies plus the SPX series. Legs that fail to resolve return na, drop out of the aggregate, and shrink the effective universe. The status table reports the live count so the user can judge whether the composite is representative.

History requirement. Each leg needs enough valid monthly history to fill the trend window and, when standardization is on, the z-score window before it contributes. The composite is na until those windows are satisfied for the live legs, so it begins only after sufficient history has accumulated.

Revision behavior. Requests use no lookahead, so the script does not read future data. Economic series are published with a lag and are forward-filled between releases, and published values can be revised after the fact. The most recent readings can therefore change as data is updated, independently of any bar-level repainting.

Symbol independence. The output does not depend on the chart symbol; it computes the same composite on any chart. Only the pane in which it is drawn follows the chart.

No claim is made regarding profitability, accuracy, or future returns. The indicator is a descriptive macro monitor.

כתב ויתור

המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.