fastqcr icon indicating copy to clipboard operation
fastqcr copied to clipboard

extend `qc_read_collection` to take list of `qc_read` not only raw files

Open MahShaaban opened this issue 6 years ago • 0 comments

Hi @kassambara

I previously suggested qc_read_collection and qc_plot_collection to handle multiple files of the fastqc output. The read function is however limited to using the raw fastqc files. I want to suggest adding a data argument to qcr_read_collection to deal with a case where the raw files are not available but rather a list of qc_read objects distributed as an R object.

The behavior of qc_read_collection can be modified to something like this

# extract paths to the demo files
qc.dir <- system.file("fastqc_results", package = "fastqcr")
qc.files <- list.files(qc.dir, full.names = TRUE)

# read list of files
qc_list <- lappy(qc.files, qc_read)

# make a collection object
qc_collection <- qc_read_collection(data = qc_list, sample_names = paste('S', 1:5, sep = ''))

MahShaaban avatar Feb 27 '19 05:02 MahShaaban