
Convert a glycoproteomics experiment to a pseudo-glycome experiment
Source:R/as-pseudo-glycome.R
as_pseudo_glycome.RdTransforms a glycoproteomics-type experiment into a glycomics-type experiment by aggregating expression values by glycan structure (if available) or glycan composition.
This function implements the "pseudo-glycome" method described in doi:10.1038/s41467-026-68579-x , which aggregates glycoproteomic data by glycans to simulate glycome data when real glycome is unavailable.
Usage
as_pseudo_glycome(
exp,
aggr_method = c("sum", "mean", "median"),
glycosite = NULL
)Arguments
- exp
A glycoproteomics
experiment()or aGlycoproteomicSE().- aggr_method
Aggregation method to use. One of "sum", "mean", or "median". Default is "sum". Note that glycopeptides can have different ionization efficiencies, so none of these methods are technically rigorous.
- glycosite
A named list specifying one glycosite for a
GlycoproteomicSE(), with scalarproteinandprotein_sitevalues. Defaults toNULL, which includes all glycosites. Site-specific filtering is not supported for legacyexperiment()objects.
Value
If exp is an experiment(), a glycomics-type experiment() with
aggregated expression values.
If exp is a GlycoproteomicSE(), a GlycomicSE() with aggregated
expression values.
The variable metadata will contain only glycan_composition and
glycan_structure (if present in input) columns.
Details
Aggregation behavior:
If
glycan_structurecolumn exists invar_info, aggregation is done by glycan structure (more specific)Otherwise, aggregation is done by
glycan_compositionExpression values are aggregated within each glycan group using the specified
aggr_method
Limitation: Glycopeptides can have different ionization efficiencies, so the aggregation operation is not technically rigorous regardless of the method used. Use results with caution.
Examples
library(glyrepr)
as_pseudo_glycome(real_experiment)
#>
#> ── GlycomicSE ──────────────────────────────────────────────────────────────────
#> ℹ Abundance assay: 12 samples, 968 variables
#> ℹ Glycan type: N
#> ℹ Row data fields: glycan_structure <struct>, glycan_composition <comp>
#> ℹ Column data fields: group <fct>
#> ℹ Metadata fields: exp_type <chr>, glycan_type <chr>, quant_method <chr>