Datasets
The US Treasury yield curve
Nine Treasury maturities move together every day. How few numbers are needed to describe that movement, and what shapes do they have?
The file, and the notebooks that read it
data
folder beside the notebook. Every notebook reads data/yields.csv
and is run from its own folder.What this data answers
There is no target column and nothing is predicted. The question is about structure: which directions carry the most variation.
Dataset overview
| Question | Nine Treasury maturities move together every day. How few numbers are needed to describe that movement, and what shapes do they have? |
| Observation | One trading day, from January 1990 to July 2026. |
| Target | None. This dataset has no outcome column. |
| Inputs | DGS3MO, DGS6MO, DGS1, DGS2, DGS3, DGS5, DGS7, DGS10, DGS30 |
| Size | 9,143 rows and 10 columns. |
How the rows are divided
No split. The Day 4 check is different in kind: the components are refitted separately on 1990 to 2007 and on 2008 to 2026, and the two sets of loadings are compared.
Data dictionary
Every column in yields.csv. The
fourth column is the one to read before modelling: a variable that is not
known when the prediction is needed cannot be used, however well it
predicts.
| Column | Type | What it means | When is this known? |
|---|---|---|---|
date | date (YYYY-MM-DD) | Trading day. | The observation date. |
DGS3MO | number, per cent | Three-month constant-maturity Treasury yield. | Published that day. |
DGS6MO | number, per cent | Six-month yield. | Published that day. |
DGS1 | number, per cent | One-year yield. | Published that day. |
DGS2 | number, per cent | Two-year yield. | Published that day. |
DGS3 | number, per cent | Three-year yield. | Published that day. |
DGS5 | number, per cent | Five-year yield. | Published that day. |
DGS7 | number, per cent | Seven-year yield. | Published that day. |
DGS10 | number, per cent | Ten-year yield. | Published that day. |
DGS30 | number, per cent | Thirty-year yield. | Published that day. |
Source and preparation
The source is Federal Reserve Bank of St. Louis, FRED constant-maturity Treasury series, nine maturities, daily, released under Public United States government series. The twenty-year maturity is absent because the Treasury suspended it between 1986 and 1993.
The nine published series were aligned on dates and rows with any missing yield were dropped.
| Step | Rows left | Why |
|---|---|---|
| Trading days with all nine maturities | 9,143 | January 1990 to July 2026 |
| Daily changes after differencing | 9,142 | the analysis uses changes, not levels |
The columns are all in percentage points, so Day 4 does not standardise them. Rescaling would throw away the genuine fact that long yields move less than short ones. That is the opposite call from the clustering, and it is made deliberately.
What this data does not establish
- A component is a direction of movement, not a cause of it.
- A large share of variance means a direction is large, not that it is important or actionable.
- The sign of a component is arbitrary. Multiplying a component and its scores by minus one leaves the description unchanged.
- The shapes are properties of this panel and these maturities.
Where it is used
- Day 4. Day 4 compresses the nine maturities into three components and reads their shapes.