Dataset Viewer
Auto-converted to Parquet Duplicate
id
int32
1
4.11M
sorting_variable
stringclasses
179 values
min_size_quantile
float64
0.2
0.2
⌀
min_stock_price
float64
min_listing_age
int32
24
24
exclude_financials
bool
2 classes
exclude_utilities
bool
2 classes
exclude_negative_book_equity
bool
1 class
exclude_negative_earnings
bool
2 classes
sorting_variable_lag
stringclasses
4 values
rebalancing
stringclasses
2 values
n_portfolios_main
float64
3
10
sorting_method
stringclasses
3 values
breakpoints_min_size_threshold
float64
0.2
0.2
⌀
n_portfolios_secondary
float64
2
5
⌀
breakpoints_exchanges
stringclasses
2 values
weighting_scheme
stringclasses
3 values
1
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
NYSE
EW
2
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
NYSE
VW
3
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
NYSE
capped VW
4
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
AMEX|NASDAQ|NYSE
EW
5
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
AMEX|NASDAQ|NYSE
VW
6
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
null
null
AMEX|NASDAQ|NYSE
capped VW
7
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
NYSE
EW
8
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
NYSE
VW
9
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
NYSE
capped VW
10
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
AMEX|NASDAQ|NYSE
EW
11
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
AMEX|NASDAQ|NYSE
VW
12
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
univariate
0.2
null
AMEX|NASDAQ|NYSE
capped VW
13
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
NYSE
EW
14
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
NYSE
VW
15
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
NYSE
capped VW
16
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
EW
17
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
VW
18
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
capped VW
19
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
NYSE
EW
20
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
NYSE
VW
21
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
NYSE
capped VW
22
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
EW
23
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
VW
24
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
capped VW
25
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
NYSE
EW
26
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
NYSE
VW
27
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
NYSE
capped VW
28
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
EW
29
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
VW
30
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
capped VW
31
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
NYSE
EW
32
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
NYSE
VW
33
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
NYSE
capped VW
34
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
EW
35
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
VW
36
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
capped VW
37
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
NYSE
EW
38
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
NYSE
VW
39
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
NYSE
capped VW
40
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
AMEX|NASDAQ|NYSE
EW
41
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
AMEX|NASDAQ|NYSE
VW
42
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
2
AMEX|NASDAQ|NYSE
capped VW
43
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
NYSE
EW
44
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
NYSE
VW
45
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
NYSE
capped VW
46
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
AMEX|NASDAQ|NYSE
EW
47
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
AMEX|NASDAQ|NYSE
VW
48
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
null
5
AMEX|NASDAQ|NYSE
capped VW
49
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
NYSE
EW
50
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
NYSE
VW
51
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
NYSE
capped VW
52
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
AMEX|NASDAQ|NYSE
EW
53
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
AMEX|NASDAQ|NYSE
VW
54
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
2
AMEX|NASDAQ|NYSE
capped VW
55
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
NYSE
EW
56
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
NYSE
VW
57
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
NYSE
capped VW
58
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
AMEX|NASDAQ|NYSE
EW
59
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
AMEX|NASDAQ|NYSE
VW
60
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
3
bivariate-independent
0.2
5
AMEX|NASDAQ|NYSE
capped VW
61
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
NYSE
EW
62
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
NYSE
VW
63
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
NYSE
capped VW
64
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
AMEX|NASDAQ|NYSE
EW
65
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
AMEX|NASDAQ|NYSE
VW
66
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
null
null
AMEX|NASDAQ|NYSE
capped VW
67
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
NYSE
EW
68
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
NYSE
VW
69
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
NYSE
capped VW
70
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
AMEX|NASDAQ|NYSE
EW
71
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
AMEX|NASDAQ|NYSE
VW
72
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
univariate
0.2
null
AMEX|NASDAQ|NYSE
capped VW
73
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
NYSE
EW
74
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
NYSE
VW
75
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
NYSE
capped VW
76
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
EW
77
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
VW
78
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
2
AMEX|NASDAQ|NYSE
capped VW
79
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
NYSE
EW
80
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
NYSE
VW
81
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
NYSE
capped VW
82
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
EW
83
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
VW
84
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
null
5
AMEX|NASDAQ|NYSE
capped VW
85
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
NYSE
EW
86
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
NYSE
VW
87
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
NYSE
capped VW
88
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
EW
89
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
VW
90
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
2
AMEX|NASDAQ|NYSE
capped VW
91
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
NYSE
EW
92
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
NYSE
VW
93
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
NYSE
capped VW
94
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
EW
95
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
VW
96
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-dependent
0.2
5
AMEX|NASDAQ|NYSE
capped VW
97
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-independent
null
2
NYSE
EW
98
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-independent
null
2
NYSE
VW
99
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-independent
null
2
NYSE
capped VW
100
abnormalaccruals
null
null
24
true
true
false
true
1m
monthly
5
bivariate-independent
null
2
AMEX|NASDAQ|NYSE
EW
End of preview. Expand in Data Studio

Tidy Finance Factor Library: Specification Grid

Lookup table that maps each specification id to its portfolio construction choices. Use it together with the Portfolio Returns dataset to select return series and to identify the choices behind each series.

Dataset Details

Dataset Description

The grid contains 4,105,728 specifications for 179 sorting variables. Each row defines a complete set of construction choices: sample exclusions, lagging convention, breakpoints, sorting method, weighting scheme, and rebalancing frequency. The id column links to the corresponding return series in the Portfolio Returns dataset.

  • Curated by: Christoph Frey (Lancaster University), Christoph Scheuch (Tidy Intelligence), Stefan Voigt (University of Copenhagen), Patrick Weiss (Reykjavík University)
  • Funded by: Danish Finance Institute
  • License: CC0 1.0

Dataset Sources

Uses

Direct Use

  • Joining with the Portfolio Returns dataset to filter or group factor returns by specific methodological choices.
  • Robustness and sensitivity analysis: selecting subsets of specifications to study how construction decisions affect factor premia.
  • Replication: documenting the exact configuration behind a reported result.

Out-of-Scope Use

  • Standalone analysis. The grid contains no return data and must be joined with the Portfolio Returns dataset via the id column.

Dataset Structure

The repository holds three kinds of Parquet files:

  • portfolio_sort_grid.parquet: the grid, with 17 columns and 4,105,728 rows.
  • portfolio_sort_grid/<sorting_variable>.parquet (e.g., portfolio_sort_grid/bm.parquet): the rows of the grid for one sorting variable, at most 23,040 rows or about 115 KB each. Together these slices hold exactly the rows of the grid. They serve clients that need one sorting variable at a time, such as the demo, which runs in the browser.
  • sorting_variables.parquet: one row per sorting variable, with its full name and the direction of its high-minus-low portfolio.

Read the grid by its file name. A reader that loads every Parquet file of the repository mixes the grid with its slices and the list of sorting variables.

Grid columns

Column Type Description
id int32 Specification identifier, the key of the Portfolio Returns dataset
sorting_variable string Sorting characteristic, named like the Open Source Asset Pricing signals (e.g., bm for book-to-market, size for market equity)
min_size_quantile double Size filter: NA (none) or 0.2 (stocks below the 20th NYSE size percentile excluded)
min_stock_price double Minimum stock price: always NA (not applied)
min_listing_age int32 Minimum listing age in months: always 24
exclude_financials bool Whether financial firms (SIC 6000-6799) are excluded
exclude_utilities bool Whether utility firms (SIC 4900-4999) are excluded
exclude_negative_book_equity bool Whether firms with negative book equity are excluded: always false
exclude_negative_earnings bool Whether firms with negative earnings are excluded
sorting_variable_lag string Lagging convention: 1m (timing of Open Source Asset Pricing), 3m, 6m, or ff (Fama-French)
rebalancing string Rebalancing frequency: monthly or annual (July)
n_portfolios_main double Number of portfolios in the main sort: 3, 5, or 10
sorting_method string univariate, bivariate-dependent, or bivariate-independent, with size as the second variable of bivariate sorts
breakpoints_min_size_threshold double Minimum size quantile of the stocks that set the main breakpoints: NA (none) or 0.2. It applies to the main breakpoints only; the size breakpoints of bivariate sorts are not screened
n_portfolios_secondary double Number of size portfolios in bivariate sorts: 2 or 5; NA for univariate sorts
breakpoints_exchanges string Exchanges whose stocks set the breakpoints: NYSE or AMEX|NASDAQ|NYSE
weighting_scheme string Portfolio weighting: EW (equal-weighted), VW (value-weighted), or capped VW (value-weighted with market capitalization capped at its 80th percentile each month)

Each set of construction choices appears three times, once per weighting scheme, with consecutive ids in the order EW, VW, capped VW.

Invalid combinations are removed: univariate sorts have no size sort, so n_portfolios_secondary is NA, and size itself is not used in bivariate sorts. Specifications whose sort produced no portfolios have no rows in the Portfolio Returns dataset; see its dataset card.

Sorting variable columns

Column Type Description
sorting_variable string Name of the sorting variable, as in the sorting_variable column of the grid
full_name string Description of the signal from the Open Source Asset Pricing documentation
direction string top_minus_bottom if the high-minus-low portfolio is long the top portfolio and short the bottom one, bottom_minus_top otherwise

The Open Source Asset Pricing signals are signed so that higher values go with higher expected returns, so every direction is top_minus_bottom.

Dataset Creation

Curation Rationale

Factor construction involves many subjective methodological choices. Rather than committing to a single specification, we enumerate all valid combinations to enable systematic robustness analysis and transparent reporting.

Source Data

Data Collection and Processing

The grid is generated programmatically from the full factorial combination of construction choices, with invalid configurations removed. See 02_define_portfolio_sorts_grid.R in the construction pipeline for the exact generation logic. 05_upload_to_huggingface.R writes the published files: the grid, its slices by sorting variable, and the list of sorting variables.

Who are the source data producers?

The grid is a methodological artifact created by the dataset authors. The sorting variables follow the Open Source Asset Pricing release (Chen and Zimmermann, 2022).

Personal and Sensitive Information

The dataset contains no personal or sensitive information. All columns describe portfolio sorting configurations.

Bias, Risks, and Limitations

  • The grid reflects the authors' choice of specification dimensions and does not cover all possible methodological variations (e.g., alternative industry classifications, different minimum listing requirements, or alternative risk-free rate definitions).
  • Some specifications may produce portfolios with very few stocks in certain months, particularly for sorting variables with limited coverage or restrictive exclusion criteria.

Recommendations

Always join with the Portfolio Returns dataset via the id column. When reporting results, cite the specific id or the full set of column values to ensure reproducibility.

Citation

BibTeX:

@article{Frey.2026,
  title={A Transparent Financial Risk Factor Library},
  author={Frey, Christoph and Scheuch, Christoph and Voigt, Stefan and Weiss, Patrick},
  year={2026},
  journal={Working Paper}
}

Dataset Card Authors

Christoph Frey, Christoph Scheuch, Stefan Voigt, Patrick Weiss

Dataset Card Contact

Stefan Voigt (stefan.voigt@econ.ku.dk), Patrick Weiss (patrickw@ru.is)

Downloads last month
205