Skip to content

yanpgwang/CrossSectionCN

Repository files navigation

CrossSectionCN

Open replication of cross-sectional return predictors on China equity data, following the catalog conventions of Chen and Zimmermann (2022).

Scope

Each entry in the predictor registry is documented with a closed-form definition, the literature attribution, the expected sign of its long–short return, the portfolio construction rule, and a record of known measurement and timing frictions in the local sample. No results from the reference catalog are republished. Every predictor is recomputed under the local accounting calendar and trading conventions; deviations from the reference catalog are part of the deliverable, not a defect of it.

Long–short returns are reported as direction-adjusted high-minus-low quintile spreads with a 30-name minimum cross-section, formed at month end and held one period. The portfolio rule is intentionally minimal — neutralisations, weighting variants, and transaction-cost overlays are deferred to follow-up work that can cite this baseline.

Build

python master.py ingest        # vendor pulls, cached locally (not redistributed)
python master.py normalize     # canonical tables
python master.py intermediate  # point-in-time joins → signal_master.parquet
python master.py factors       # one parquet per signal under pyData/factors/
python -m reports.build_site_data    # long–short returns + per-factor JSON snapshots
python -m reports.build_quarto_data  # Quarto sources from the snapshots

The published site is fully determined by the snapshots under quarto/_data/, which are versioned alongside the code that produced them. .github/workflows/publish.yml renders the Quarto project and deploys to GitHub Pages on every push to main; the pipeline above is a deliberate local operation and is not executed in CI.

Repository layout

data/        vendor ingest, normalisation, PIT joins, signal_master assembly
factors/     predictor specifications and the seed factor runner
reports/     site-data generation (parquet → json → qmd)
quarto/      Quarto project; rendered output lives in _site/
factor_doc.csv   per-predictor registry: family, formula, attribution, expected sign,
                 portfolio rule, known data issues

Reference

Chen, A. Y. and Zimmermann, T. (2022). Open source cross-sectional asset pricing. Critical Finance Review, 11 (2): 207–264.

Reference implementation: https://github.com/OpenSourceAP/CrossSection.

License

MIT — see LICENSE. Vendor data is subject to its own licence and is not redistributed.

About

Open replication of cross-sectional return predictors on China equity data, following Chen and Zimmermann (2022).

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors