OmitPoorSamples: A function to remove columns with a high ratio of missing...

Description Usage Arguments Value See Also Examples

Description

A function to remove columns with a high ratio of missing data from a dataframe. (e.g. samples from genotype)

Usage

1
OmitPoorSamples(gt, min.qual, dp = NULL, verbose = TRUE)

Arguments

gt

A dataframe to process (e.g. a genotype dataframe)

min.qual

The minimum valid data ratio under which the column will be deleted from the dataframe (from 0 to 1)

dp

An optionnal dataframe on which the process of gt will be executed too (e.g. a depth dataframe)

verbose

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

Value

A dataframe or a list of dataframes. If the dp is not set, return gt without its columns where the missing data ratio was too high. If the dp is set, return the modified gt as list$gt; list$dp is the modified dp dataframe with the same missing columns as list$gt.

See Also

OmitPoorVariants

Examples

1
2
3
4
5
6
## Not run: 
OmitPoorSamples(genotype, 0.15)
OmitPoorSamples(genotype, 0.2, dp = depth)
OmitPoorSamples(genotype, 0.2, verbose = FALSE)

## End(Not run)

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