set_threshold: Set threshold on a classification method.

Description Usage Arguments Value Examples

View source: R/set_threshold.R

Description

Function truncates the genotypes (column gtype) given a threshold (cutoff) an classification method. This causes that all genotypes below threshold defined in threshol will be called as NC (no-call)

Usage

1
set_threshold(.data,clfcol,threshold)

Arguments

.data

dataframe from scbasic or compatible

clfcol

column with classification score

threshold

threshold from 0 to 1

Value

data frame with gtype set to NC for classification score below chosen threshold

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
setwd(system.file(package='SureTypeSCR'))
samplesheet=system.file('files/GSE19247_example.csv',package='SureTypeSCR')
manifest=system.file('files/HumanCytoSNP-12v2_H.bpm',package='SureTypeSCR')
cluster=system.file('files/HumanCytoSNP-12v2_H.egt',package='SureTypeSCR')

##Load data
#df=scbasic(manifest,cluster,samplesheet)
##changing Gencall score threshold 
#df %>% set_threshold(clfcol='score',threshold=0.5) %>% callrate()
##with higher threshold we expect lower call rate
#df %>% set_threshold(clfcol='score',threshold=0.75) %>% callrate()

Meiomap/SureTypeSCR documentation built on Dec. 17, 2021, 3:22 a.m.