getMarkers: Get the organelle markers in an 'MSnSet'

View source: R/MSnSet.R

getMarkersR Documentation

Get the organelle markers in an MSnSet

Description

Convenience accessor to the organelle markers in an MSnSet. This function returns the organelle markers of an MSnSet instance. As a side effect, it print out a marker table.

Usage

getMarkers(object, fcol = "markers", names = TRUE, verbose = TRUE)

Arguments

object

An instance of class "MSnSet".

fcol

The name of the markers column in the featureData slot. Default is "markers".

names

A logical indicating if the markers vector should be named. Ignored if markers are encoded as a matrix.

verbose

If TRUE, a marker table is printed and the markers are returned invisibly. If FALSE, the markers are returned.

Value

A character (matrix) of length (ncol) ncol(object), depending on the vector or matrix encoding of the markers.

Author(s)

Laurent Gatto

See Also

See getMarkerClasses to get the classes only. See markers for details about spatial markers storage and encoding.

Examples

library("pRolocdata")
data(dunkley2006)
## marker vectors
myVmarkers <- getMarkers(dunkley2006)
head(myVmarkers)
## marker matrix
dunkley2006 <- mrkVecToMat(dunkley2006, mfcol = "Markers")
myMmarkers <- getMarkers(dunkley2006, fcol = "Markers")
head(myMmarkers)

lgatto/pRoloc documentation built on Oct. 23, 2024, 12:51 a.m.