SplitVcf: A function to split a vcfR::VCF object in two vcfR::VCF...

Description Usage Arguments Value Examples

Description

A function to split a vcfR::VCF object in two vcfR::VCF object according to a logical vector

Usage

1
SplitVcf(vcf, survival, verbose = TRUE)

Arguments

vcf

The original vcfR::VCF object to split

survival

A logical vector for splitting the data into two vcfR::VCF objects. The length of the vector must match the number of samples in the VCF file.

verbose

Logical. If TRUE (default), report status of the process along the execution.

Value

A list of vcfR:VCF objects. list$alive is the vcfR::VCF object containing the samples which position corresponds with a TRUE in the survival vector. The other samples are contained in list$dead as an other vcfR::VCF object.

Examples

1
2
3
4
5
## Not run: 
SplitVcf(vcf, c(TRUE, TRUE, FALSE, ...))
SplitVcf(vcf, survival.vector, verbose = FALSE)

## End(Not run)

laurentlab-mpipz/rsurvival documentation built on May 29, 2019, 9:14 a.m.