Learn R Programming

snpEnrichment (version 1.1-0)

reSample: Compute enrichment analysis on an Enrichment object

Description

After initFiles and readEnrichment has been run. reSample computes a statistic value and a p-value for each chromosomes and for the whole genome.

Usage

reSample(object, nSample = 100, sigThresh = 0.05, 
         MAFpool = c(0.05, 0.10, 0.2, 0.3, 0.4, 0.5),
         extendMethod = "ld", mc.cores = detectCores())

Arguments

object
[Enrichment or Chromosome]: an object to be updated. It is intended, an object returned by the readEnrichment function.
nSample
[numeric]: the number of resampling done by reSample for p-values computation (minimum is 100).
sigThresh
[numeric]: statistical threshold for signal (e.g. sigThresh = 0.05 for a given GWAS signal) used to compute an Enrichment Ratio.
MAFpool
[vector(numeric)]: either a numeric vector giving the breaks points of intervals into which SNP's MAF (Minor Allele Frequency) is to be split.
extendMethod
[character]: character string naming the method to be used to extend the list of eSNPs. Default is "ld", the list of eSNPs is extended with all SNPs in LD (r^2 threshold, defined in initFiles). O
mc.cores
[numeric]: The number of cores to use, i.e. at most how many child processes will be run simultaneously. The option is initialized with detectCores. Must be at least one, and parallelization requires at least two cores.

Value

  • Return the object given in argument, updated by the resampling results.

See Also

Overview : snpEnrichment-package Classes : Enrichment, Chromosome, SNP Methods : plot, reSample, excludeSNP, compareEnrichment, enrichment, is.enrichment, chromosome, is.chromosome Functions : initFiles, writeLD, readEnrichment

Examples

Run this code
# data(toyM1)
# reSample(object = toyM1, 
         # nSample = 10, 
         # sigThresh = 0.05, 
         # MAFpool = c(0.05, 0.10, 0.2, 0.3, 0.4, 0.5), 
         # extendMethod = "ld", mc.cores = detectCores())
# toyM1

Run the code above in your browser using DataLab