Learn R Programming

sumFREGAT (version 1.0.0)

prep.score.files: Prepare score files

Description

Calculates Z scores from P values and beta input

Usage

prep.score.files(input.file, output.file.prefix)

Arguments

input.file

a file with the following columns: "CHROM": chromosome "POS": positions "ID": names of genetic variants, same as in files with genetic correlations "REF": reference allele "ALT": alternative allele "P": p value "BETA": effect size (betas and genetic correlations should be calculated for the same genotype coding) "EAF": effect allele freequency For example: CHROM POS ID REF ALT pvalue beta EAF 1 196632134 1:196632134 C T 0.80675 0.22946 0.00588 1 196632386 1:196632386 G A 0.48694 0.65208 0.00588 1 196632470 1:196632470 A G 0.25594 -0.19280 0.19412 Avoid rounding of betas and pvalues as this can affect the precision of regional tests.

output.file.prefix

if not set, the input file name will be used as output prefix.

Value

does not return any value, writes output files with Z scores to be used in any type of gene-based analysis: SKAT(), BT(), MLR(), FLM(), PCA().

Examples

Run this code
# NOT RUN {
input.file <- system.file("testfiles/CFH.pvalues.dat",
	package = "sumFREGAT")
prep.score.files(input.file, "CFH.scores")

# }

Run the code above in your browser using DataLab