mrkConsProfiles: Marker consensus profiles

View source: R/utils.R

mrkConsProfilesR Documentation

Marker consensus profiles

Description

A function to calculate average marker profiles.

Usage

mrkConsProfiles(object, fcol = "markers", method = mean)

Arguments

object

An instance of class MSnSet.

fcol

Feature meta-data label (fData column name) defining the groups to be differentiated using different colours. Default is markers.

method

A function to average marker profiles. Default is mean.

Value

A matrix of dimensions number of clusters (exluding unknowns) by number of fractions.

Author(s)

Laurent Gatto and Lisa M. Breckels

See Also

The mrkHClust function to produce a hierarchical cluster.

Examples

library("pRolocdata")
data(dunkley2006)
mrkConsProfiles(dunkley2006)
mrkConsProfiles(dunkley2006, method = median)
mm <- mrkConsProfiles(dunkley2006)
## Reorder fractions
o <- order(dunkley2006$fraction)
## Plot mean organelle profiles using the
## default pRoloc colour palette.
matplot(t(mm[, o]), type = "l",
        xlab = "Fractions", ylab = "Relative intensity",
        main = "Mean organelle profiles",
        col = getStockcol(), lwd = 2, lty = 1)
## Add a legend
addLegend(markerMSnSet(dunkley2006), where = "topleft")

lgatto/pRoloc documentation built on Nov. 27, 2024, 12:14 a.m.