PRS-CS and PRS-CSx
Practical workflows for Bayesian polygenic scoring
This guide collects the commands and checks I commonly need when calculating polygenic scores with PRS-CS and PRS-CSx. It focuses on moving from harmonized GWAS summary statistics to posterior SNP effects, individual-level scores, and a basic association model.
Which method should I use?
| Method | Discovery GWAS | Main use |
|---|---|---|
| PRS-CS | One population | Infer posterior SNP effects using an ancestry-matched LD reference panel. |
| PRS-CSx | Two or more populations | Share information across populations and improve cross-population prediction. |
The LD reference panel should match the ancestry of the discovery GWAS, while the target .bim file tells the software which variants are available in the scoring dataset.
Input format
The recommended format uses BETA or OR together with SE:
SNP A1 A2 BETA SE
rs4970383 C A -0.0064 0.0090
rs4475691 C T -0.0145 0.0094
rs13302982 A G -0.0232 0.0199
A1 is the effect allele. When OR is supplied, SE must be the standard error of the log odds ratio.
The official tools also accept BETA/OR with P, but SE is preferred. Extremely small p-values may be truncated in the p-value input route and reduce prediction accuracy for traits with highly significant loci.
Before running
- Confirm the genome build and variant identifiers.
- Confirm that
A1is the effect allele in every input file. - Remove duplicate or ambiguous records according to the analysis plan.
- In PRS-CSx, list the GWAS files, sample sizes, and population labels in the same population order. If the European GWAS is listed first, its sample size and
EURlabel must also be listed first. - Use an independent validation set if tuning parameters or combining population-specific scores.
Reusable command templates
The repository includes compact shell scripts for running a chromosome 22 test before expanding to the autosomes:
Edit the paths and sample sizes at the top of each file before running it. The tutorial pages remain the source for explanations and analysis decisions; the scripts are practical starting points.