top_data: Retain only top SNPs by variance explained

Description Usage Arguments Value See Also

View source: R/ArchitectureSimulate.R

Description

Filter data to keep only the top k by proportion of variance explained, which must be provided in a column called 'propexplained'.

Usage

1
top_data(testdata, k = 100)

Arguments

testdata

The data frame containing frequency in the first column.

k

The number of SNPs to retain

Value

A dataframe the same shape as provided with only the top k SNPs.

See Also

make_test_data which simulates the data and gives a complete example.


danjlawson/robustarchitecture documentation built on Dec. 19, 2021, 8:09 p.m.