Rbec {Rbec} | R Documentation

## Reference-based error correction of amplicon sequencing data

### Description

This function corrects the amplicon sequencing data from synthetic communities where the reference sequences are known a priori

### Usage

    Rbec(fastq, reference, outdir, threads=1, sampling_size=5000, ascii=33, min_cont_abs=0.03)

### Arguments

`fastq` | the path of the fastq file containg merged amplicon sequencing reads (Ns are not allowed in the reads)
`reference` | the path of the unique reference sequences, each sequence must be in one line (Ns are not allowed in the sequences)
`outdir` | the output directory, which should be created by the user
`threads` | the number of threads used, default 1
`sampling_size` | the sampling size for calculating the error matrix, default 5000
`ascii` | ascii characters used to encode phred scores (33 or 64), default 33
`min_cont_abs` | the relative abundance of unique tgas for detecting contamination sequences that can't be corrected by any of the references

### Details

Ruben Garrido-Oter's group, Plant-Microbe interaction, Max Planck Institute for Plant Breeding Research

### Value

lambda_final.out the lambda value and pvalue of the Poisson distribution for each read

error_matrix_final.out the error matrix in the final iteration

strain_table.txt the strain composition of the sample

contamination_seq.fna the potential sequences generated by contaminants

rbec.log percentage of corrected reads, which can be used to predict contaminated samples

### Author(s)

Pengfan Zhang

### Examples

    fastq <- system.file("extdata", "test_raw_merged_reads.fastq.gz", package = "Rbec")

    ref <- system.file("extdata", "test_ref.fasta", package = "Rbec")

    Rbec(fastq=fastq, reference=ref, outdir=tempdir(), threads=1, sampling_size=500, ascii=33)

[Package Rbec version 1.0.0 Index]