I/0

The API for Input and Output (I/O) classes and functions in ./sushie/io.py file.

Classes

class sushie.io.CVData[source]

Define the cross validation data object.

class sushie.io.CleanData[source]

Define the clean data object ready for the future inference.

class sushie.io.RawData[source]

Define the raw data object for the future data cleaning.

Functions

sushie.io.read_data(n_pop: int, ...) List[RawData][source]

Read in pheno, covar, and genotype data and convert it to raw data object.

sushie.io.read_triplet(path) Tuple[DataFrame, DataFrame, Array][source]
Read in genotype data in plink 1 format.

pandas_plink package is used to read in the plink file.

sushie.io.read_vcf(path: str) Tuple[DataFrame, DataFrame, Array][source]
Read in genotype data in vcf format.

cyvcf2 package is used to read in the vcf file. gt_types are used to determine the genotype matrix. It it is UNKNOWN, it will be coded as NA.

sushie.io.read_bgen(path: str) Tuple[DataFrame, DataFrame, Array][source]
Read in genotype data in bgen 1.3 format.

bgen-reader package is used to read in the bgen file.

sushie.io.read_gwas(path: str, header: List[str], ...) DataFrame[source]

Read in GWAS data in tsv file.

sushie.io.read_ld(path: str) Array[source]

Read in ld data in tsv file.

sushie.io.output_cs(result: List[SushieResult], ...) DataFrame[source]

Output credible set (after pruning for purity) file *cs.tsv (see Credible Set).

sushie.io.output_weights(result, ...) DataFrame[source]

Output prediction weights file *weights.tsv (see Prediction Weights).

sushie.io.output_alphas(result, ...) DataFrame[source]

Output full credible set (before pruning for purity) file *alphas.tsv (see Full Credible Set with Alphas).

sushie.io.output_her(data: CleanData, output: str, ...) DataFrame[source]

Output heritability estimation file *her.tsv (see Heritability Estimation).

sushie.io.output_corr(result: List[SushieResult], ...) DataFrame[source]

Output effect size correlation file *corr.tsv (see Effect Size Correlation).

sushie.io.output_cv(cv_res: List, sample_size, ...) DataFrame[source]
Output cross validation file *cv.tsv for

future FUSION pipline (see Cross Validation).

sushie.io.output_numpy(result: List[SushieResult], ...) None[source]

Output all results in *.npy file (no compress option) (see Everything).


Last update: Oct 27, 2024