applyThresholdCompartment: Apply thresholds to compartments

Description Usage Arguments Value Examples

View source: R/applyThresholdToCompartment.R

Description

Apply thresholds for all predictions to increase the true positive rate and remove poor classification.

Usage

1
applyThresholdCompartment(all.repA, all.repB, threshold.df)

Arguments

all.repA

data.frame; all predictions and probablity vectors for each protein in replicate A

all.repB

data.frame; all predictions and probablity vectors for each protein in replicate B

threshold.df

data.frame; collection od precision and recall values for each compaartment

Value

c.cls.df

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
{

df <- loadData(SubCellBarCode::hcc827Ctrl)

c.prots <- calculateCoveredProtein(rownames(df), markerProteins[,1])

set.seed(7)
c.prots <- sample(c.prots, 550)
cls <- svmClassification(c.prots, df, markerProteins)

test.A <- cls[[1]]$svm.test.prob.out
test.B <- cls[[2]]$svm.test.prob.out

t.c.df <- computeThresholdCompartment(test.A, test.B)

all.A <- cls[[1]]$all.prot.pred
all.B <- cls[[2]]$all.prot.pred

c.cls.df <- applyThresholdCompartment(all.A, all.B, t.c.df)
}

SubCellBarCode documentation built on Nov. 8, 2020, 5:26 p.m.