bc_auto_cutoff: Finds barcode count cutoff point

bc_auto_cutoffR Documentation

Finds barcode count cutoff point

Description

Finds the cutoff point for the barcode count filtering based on the barcode count distribution.

Usage

bc_auto_cutoff(barcodeObj, useCleanBc = TRUE)

## S4 method for signature 'BarcodeObj'
bc_auto_cutoff(barcodeObj, useCleanBc = TRUE)

Arguments

barcodeObj

A BarcodeObj object.

useCleanBc

A logical value, if TRUE, the cleanBc slot in the BarcodeObj object will be used, otherwise the messyBc slot will be used.

Details

The one dimension kmeans clustering is applied to identify the "true barcode" based on the read count. The algorithm detail is: 1. Remove the barcodes with counts below the median of counts. 2. Transform the count by log2(x+1). 3. Apply the 1-dimension clustering to the log count, with the cluster number of 2 and weights of the log count. 4. Choose the minimum count value in the cluster with more counts as cutoff point.

For more info about 1 dimension kmeans used here please refer to Ckmeans.1d.dp.

Value

a numeric vector of the cutoff point.

Examples


data(bc_obj)

bc_auto_cutoff(bc_obj)


wenjie1991/CellBarcode documentation built on April 17, 2024, 4:40 a.m.