filterFrequency: filter clonotypes presented in less than a proportion of...

Description Usage Arguments Value Examples

Description

A function that returns a function with values for A, p and na.rm bound to the specified values. The function takes a single vector, x, as an argument. When the returned function is evaluated it returns TRUE if the proportion of values in x that are larger than A is at least p.

Usage

1
filterFrequency(x, freq = 0.2, group = NULL)

Arguments

x

an object of class RepSeqExperiment.

freq

a number between 0 & 1. A clonotype is retained if it is present in a proportion of samples that excces This is the proportion of samples

group

a factor in sampleData, if null, freq is applied to the group having the smallest number of membres.

Value

an object of class RepSeqExperiment satisfying the conditions.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
# The package RepSeqData contains example datasets 
library(RepSeq)
library(RepSeqData)
sData(RepSeqData)
# get overlap clonotypes between the sample S01 and the sample S02
filterdata <- filterFrequency(RepSeqData, 
                       freq = 0.2, 
                       group = "quantity")  
filterdata

## End(Not run)

ph-pham/RepSeq documentation built on Dec. 22, 2021, 7:47 a.m.