plot_IDRate: Plot percent of identified MS/MS for each Raw file.

View source: R/fcn_plots.R

plot_IDRateR Documentation

Plot percent of identified MS/MS for each Raw file.

Description

Useful for a first overall impression of the data.

Usage

plot_IDRate(data, id_rate_bad, id_rate_great, label_ID)

Arguments

data

A data.frame with columns as described above

id_rate_bad

Number below which the ID rate is considered bad

id_rate_great

Number above which the ID rate is considered great

label_ID

Named vector with colors for the categories given in data$cat

Details

The input is a data.frame with columns 'fc.raw.file' - name of the Raw file 'ms.ms.identified....' - fraction of identified MS/MS spectra in percent 'cat' - identification category as arbitrary string where each row represents one Raw file.

Value

GGplot object

Examples

 id_rate_bad = 20; id_rate_great = 35;
 label_ID = c("bad (<20%)" = "red", "ok (...)" = "blue", "great (>35%)" = "green")
 data = data.frame(fc.raw.file = paste('file', letters[1:3]),
                   ms.ms.identified.... = rnorm(3, 25, 15))
 data$cat = factor(cut(data$ms.ms.identified....,
                       breaks=c(-1, id_rate_bad, id_rate_great, 100),
                       labels=names(label_ID)))                  
 plot_IDRate(data, id_rate_bad, id_rate_great, label_ID)


PTXQC documentation built on Sept. 21, 2022, 9:10 a.m.