calibrated prediction across diverse contexts
Project description
CalPred (Calibrated Prediction Intervals for Polygenic Scores Across Diverse Contexts)
The package is still in early development. And therefore any comments/suggestions are highly appreciated.
See companion manuscript github repository for analysis scripts used in the manuscript.
Installation
git clone https://github.com/KangchengHou/calpred.git && cd calpred/
Rscript -e "install.packages(c('statmod', 'Rchoice', 'logger', 'optparse', 'glue'), repos='https://cran.rstudio.com')" # calpred dependency
Rscript -e "install.packages(c('devtools', 'ggplot2', 'dplyr', 'patchwork'), repos='https://cran.rstudio.com')" # for example notebooks
Quick example
# df must have person ID as 1st column, and should not contain missing data
# y_col is the column name of the trait of interest
# mean_cols and sd_cols are columns fot fitting the mean and standard deviation
# with names separated by commas
# <out_prefix>.fitted.tsv (fitted mean and sd) and <out_prefix>.coef.tsv (coefficients) will be generated
# see toy/simulate.ipynb for the data simulation process
Rscript calpred.cli.R \
--df toy/trait.tsv \
--y_col pheno \
--mean_cols pgs,ancestry,age,sex \
--sd_cols pgs,ancestry,age,sex \
--out_prefix toy/trait
Example notebooks
Upload to PyPI
python setup.py sdist
twine upload dist/*
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
calpred-0.1.tar.gz
(12.4 kB
view hashes)