write_fastq: Write data to a fastq file.

View source: R/RcppExports.R

write_fastqR Documentation

Write data to a fastq file.

Description

Write data to a fastq file.

Usage

write_fastq(df, path)

Arguments

df

The dataframe of sequence data to write to file. The dataframe must contain the columns: "header", "sequence", "strand", and "qual". Other columns in the dataframe are permitted but will be ignored.

path

Path or connection to write to.

Examples

fastq_ex_dat = data.frame(
    header = c("seq1", "seq2", "seq3"),
    sequence = c("ATGC", "AATTGGCC", "TGACTGAC"),
    strand = c("+", "+","+"),
    qual = c("~~ua", "~AZ~ngZO", "lvykl~Qv"),
    stringsAsFactors = FALSE)
data = write_fastq(fastq_ex_dat, "example_output.fastq")

CNuge/CamBioR documentation built on May 28, 2022, 12:23 a.m.