Class SequencingQcMetricsServiceImpl
java.lang.Object
ubic.gemma.core.analysis.preprocess.qc.SequencingQcMetricsServiceImpl
- All Implemented Interfaces:
SequencingQcMetricsService
@Service
public class SequencingQcMetricsServiceImpl
extends Object
implements SequencingQcMetricsService
Streams
report_general_stats_data out of the MultiQC report and resolves its row keys to
bioAssays.
Two things about that file drive the implementation:
- The whole report is around 5.5 MB, of which the general-stats block is about 1% — the rest is
report_plot_data. It is read with the streaming parser and every other top-level field is skipped, so the plot data is never materialized. - Row keys are not uniformly sample accessions. Measured over 80 reports on the production
metadata volume: 3055 rows keyed by the bare accession, 1244 by an accession with a run or mate
suffix (
GSM5029427_1,GSM5029427_SRR13191146_2), and 1541 by an SRA run accession alone, which Gemma does not record and so cannot be joined. The split falls along module lines — STAR and RSEM key by sample (uniquely_mapped_percentwas sample-level in 79 of those 80 reports), FastQC keys by FASTQ file (percent_duplicatesin 5 of 80).
- Author:
- gembro
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionObtain the sequencing QC metrics for an experiment.
-
Constructor Details
-
SequencingQcMetricsServiceImpl
public SequencingQcMetricsServiceImpl()
-
-
Method Details
-
getSequencingQcMetrics
public Optional<SequencingQcMetrics> getSequencingQcMetrics(ExpressionExperiment ee) throws IOException Description copied from interface:SequencingQcMetricsServiceObtain the sequencing QC metrics for an experiment.The experiment's bioAssays must already be thawed (
ExpressionExperimentService.thawBioAssays(ExpressionExperiment)): this reads their accessions and read counts.- Specified by:
getSequencingQcMetricsin interfaceSequencingQcMetricsService- Returns:
- the metrics, or
Optional.empty()when the experiment has neither a MultiQC report nor a read count on any assay, i.e. when there is nothing to show. - Throws:
IOException- if the report exists but cannot be read
-