hamming_filter: Filter reference barcodes with a given read using hamming...

Description Usage Arguments Examples

View source: R/hamming_filter.R

Description

The reference barcodes are first constructed into a tree. Hamming distance between each barcode and the given read is calculated. The barcodes with hamming distance smaller than the specify threshold will be return.

Usage

1
hamming_filter(barcodes, read, threshold = 2)

Arguments

barcodes

the file path of the fasta file

read

the output file path of the fastq sequence

Examples

1
2
out = hamming_filter(c("ATTCG", "ATTCA", "AAAAA", "AATAA"), "ATTCG")
out == c("ATTCA", "ATTCG") # TRUE TRUE

clintko/BarcodeMatcher documentation built on May 30, 2019, 12:02 p.m.