getBootCI: Compute variance partition coefficition (VPC) confidence...

Description Usage Arguments Value Examples

Description

Compute VPC CI based on parametric bootstrap for one or more features.

Usage

1
2
getBootCI(CountMatrix, Strains, which.features, num.boot, method = "NB-fit",
  alpha = 0.05, optimizer = "nlminb")

Arguments

CountMatrix

A G\times N count matrix. G is the number of features; N is the total number of samples.

Strains

A 1\times N vector of strain labels corresponding to each sample.

which.features

A 1\times k vector of select feature numbers for which CI is desired. k≤q G.

num.boot

Number of bootstraps.

method

Which method should be used, "CP-fit", "NB-fit" (default), or "VST". "VST" method bootstraps data under negative binomial mixed models.

alpha

A numerical value between 0 and 1, indicating the significance level of the CI. The CI will be 100*(1-alpha) percent CI. Default value is 0.05.

optimizer

A character string that determines which optimization routine is to be used. It is only used for method = "CP-fit". Possible choices are "nlminb" (default), "L-BFGS-B", and "bobyqa".

Value

A list of two objects. The first object is a k \times 2 matrix containing the CI. The second object consists of a k \timesnum.boot matrix of all bootsrapped VPC values.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Compute CI based on 100 bootstrap samples for the first feature 
##  under NBMM. It takes a few minutes.
NBboot <- getBootCI(simData, strains, 1, 100)
## Extract CI
NBboot.ci <- NBboot[[1]]
## Extract vpcs
NBboot.vpc <- NBboot[[2]]

## Compute CI based on 100 bootstrap samples for the first feature
##  under vst. 
VSTboot <- getBootCI(simData, strains, 1, 100, method = "VST")

KechrisLab/HeritSeq documentation built on May 8, 2019, 4:48 p.m.