R/class-Cerebro_v1.3.R
Cerebro_v1.3.RdA Cerebro_v1.3 object is an R6 class that contains several types of
data that can be visualized in Cerebro.
A new Cerebro_v1.3 object.
versioncerebroApp version that was used to create the object.
experimentlist that contains meta data about the data set,
including experiment name, species, date of export.
technical_infolist that contains technical information
about the analysis, including the R session info.
parameterslist that contains important parameters that
were used during the analysis, e.g. cut-off values for cell filtering.
groupslist that contains specified grouping variables and
and the group levels (subgroups) that belong to each of them. For each
grouping variable, a corresponding column with the same name must exist
in the meta data.
cell_cyclevector that contains the name of columns in the
meta data that contain cell cycle assignments.
gene_listslist that contains gene lists, e.g.
mitochondrial and/or ribosomal genes.
expressionmatrix-like object that holds transcript counts.
meta_datadata.frame that contains cell meta data.
projectionslist that contains projections/dimensional
reductions.
most_expressed_geneslist that contains a data.frame
holding the most expressed genes for each grouping variable that was
specified during the call to getMostExpressedGenes.
marker_geneslist that contains a list for every
method that was used to calculate marker genes, and a data.frame
for each grouping variable, e.g. those that were specified during the
call to getMarkerGenes.
enriched_pathwayslist that contains a list for
every method that was used to calculate marker genes, and a
data.frame for each grouping variable, e.g. those that were
specified during the call to getEnrichedPathways or
performGeneSetEnrichmentAnalysis.
treeslist that contains a phylogenetic tree (class
phylo) for grouping variables.
trajectorieslist that contains a list for every
method that was used to calculate trajectories, and, depending on the
method, a data.frame or list for each specific trajectory,
e.g. those extracted with extractMonocleTrajectory.
extra_materiallist that can contain additional material
related to the data set; tables should be stored in data.frame
format in a named list called `tables`
new()Create a new Cerebro_v1.3 object.
Cerebro_v1.3$new()
A new Cerebro_v1.3 object.
setVersion()Set the version of cerebroApp that was used to generate this
object.
Cerebro_v1.3$setVersion(version)
versionVersion to set.
getVersion()Get the version of cerebroApp that was used to generate this
object.
Cerebro_v1.3$getVersion()
Version as package_version class.
checkIfGroupExists()Safety function that will check if a provided group name is present in
the groups field.
Cerebro_v1.3$checkIfGroupExists(group_name)
group_nameGroup name to be tested
checkIfColumnExistsInMetadata()Safety function that will check if a provided group name is present in the meta data.
Cerebro_v1.3$checkIfColumnExistsInMetadata(group_name)
group_nameGroup name to be tested.
addExperiment()Add information to experiment field.
Cerebro_v1.3$addExperiment(field, content)
fieldName of the information, e.g. organism.
contentActual information, e.g. hg.
getExperiment()Retrieve information from experiment field.
Cerebro_v1.3$getExperiment()
list of all entries in the experiment field.
addParameters()Add information to parameters field.
Cerebro_v1.3$addParameters(field, content)
fieldName of the information, e.g. number_of_PCs.
contentActual information, e.g. 30.
getParameters()Retrieve information from parameters field.
Cerebro_v1.3$getParameters()
list of all entries in the parameters field.
addTechnicalInfo()Add information to technical_info field.
Cerebro_v1.3$addTechnicalInfo(field, content)
fieldName of the information, e.g. R.
contentActual information, e.g. 4.0.2.
getTechnicalInfo()Retrieve information from technical_info field.
Cerebro_v1.3$getTechnicalInfo()
list of all entries in the technical_info field.
addGroup()Add group to the groups registered in the groups field.
Cerebro_v1.3$addGroup(group_name, levels)
group_nameGroup name.
levelsvector of group levels (subgroups).
getGroups()Retrieve all names in the groups field.
Cerebro_v1.3$getGroups()
vector of registered groups.
getGroupLevels()Retrieve group levels for a group registered in the groups field.
Cerebro_v1.3$getGroupLevels(group_name)
group_nameGroup name for which to retrieve group levels.
vector of group levels.
setMetaData()Set meta data for cells.
Cerebro_v1.3$setMetaData(table)
tabledata.frame that contains meta data for cells. The
number of rows must be equal to the number of rows of projections and
the number of columns in the transcript count matrix.
getMetaData()Retrieve meta data for cells.
Cerebro_v1.3$getMetaData()
data.frame containing meta data.
addGeneList()Add a gene list to the gene_lists.
Cerebro_v1.3$addGeneList(name, genes)
nameName of the gene list.
genesvector of genes.
getGeneLists()Retrieve gene lists from the gene_lists.
Cerebro_v1.3$getGeneLists()
list of all entries in the gene_lists field.
setExpression()Set transcript count matrix.
Cerebro_v1.3$setExpression(counts)
countsmatrix-like object that contains transcript counts
for cells in the data set. Number of columns must be equal to the number
of rows in the meta_data field.
getCellNames()Get names of all cells.
Cerebro_v1.3$getCellNames()
vector containing all cell names/barcodes.
getGeneNames()Get names of all genes in transcript count matrix.
Cerebro_v1.3$getGeneNames()
vector containing all gene names in transcript count matrix.
getMeanExpressionForGenes()Retrieve mean expression across all cells in the data set for a set of genes.
Cerebro_v1.3$getMeanExpressionForGenes(genes)
genesNames of genes to extract; no default.
data.frame containing specified gene names and their respective
mean expression across all cells in the data set.
getMeanExpressionForCells()Retrieve (mean) expression for a single gene or a set of genes for a given set of cells.
Cerebro_v1.3$getMeanExpressionForCells(cells = NULL, genes = NULL)
cellsNames/barcodes of cells to extract; defaults to NULL,
which will return all cells.
genesNames of genes to extract; defaults to NULL, which
will return all genes.
vector containing (mean) expression across all specified genes in
each specified cell.
getExpressionMatrix()Retrieve transcript count matrix.
Cerebro_v1.3$getExpressionMatrix(cells = NULL, genes = NULL)
cellsNames/barcodes of cells to extract; defaults to NULL,
which will return all cells.
genesNames of genes to extract; defaults to NULL, which
will return all genes.
Dense transcript count matrix for specified cells and genes.
setCellCycle()Add columns containing cell cycle assignments to the cell_cycle
field.
Cerebro_v1.3$setCellCycle(cols)
colsvector of columns names containing cell cycle
assignments.
getCellCycle()Retrieve column names containing cell cycle assignments.
Cerebro_v1.3$getCellCycle()
vector of column names in meta data.
addProjection()Add projections (dimensional reductions).
Cerebro_v1.3$addProjection(name, projection)
nameName of the projection.
projectiondata.frame containing positions of cells in
projection.
availableProjections()Get list of available projections (dimensional reductions).
Cerebro_v1.3$availableProjections()
vector of projections / dimensional reductions that are available.
getProjection()Retrieve data for a specific projection.
Cerebro_v1.3$getProjection(name)
nameName of projection.
data.frame containing the positions of cells in the projection.
addTree()Add phylogenetic tree to trees field.
Cerebro_v1.3$addTree(group_name, tree)
group_nameGroup name that this tree belongs to.
treePhylogenetic tree as phylo object.
getTree()Retrieve phylogenetic tree for a specific group.
Cerebro_v1.3$getTree(group_name)
group_nameGroup name for which to retrieve phylogenetic tree.
Phylogenetic tree as phylo object.
addMostExpressedGenes()Add table of most expressed genes.
Cerebro_v1.3$addMostExpressedGenes(group_name, table)
group_nameName of grouping variable that the most expressed genes
belong to. Must be registered in the groups field.
tabledata.frame that contains the most expressed genes.
getGroupsWithMostExpressedGenes()Retrieve names of grouping variables for which most expressed genes are available.
Cerebro_v1.3$getGroupsWithMostExpressedGenes()
vector of grouping variables for which most expressed genes are
available.
getMostExpressedGenes()Retrieve table of most expressed genes for a grouping variable.
Cerebro_v1.3$getMostExpressedGenes(group_name)
group_nameGrouping variable for which most expressed genes should be retrieved.
data.frame that contains most expressed genes for group levels of
the specified grouping variable.
addMarkerGenes()Add table of marker genes.
Cerebro_v1.3$addMarkerGenes(method, name, table)
methodName of method that was used to generate the marker genes.
nameName of table. This name will be used to select the table in
Cerebro. It is recommended to use the grouping variable, e.g.
sample.
tabledata.frame that contains the marker genes.
getMethodsForMarkerGenes()Retrieve names of methods that were used to generate marker genes.
Cerebro_v1.3$getMethodsForMarkerGenes()
vector of names of methods that were used to generate marker
genes.
getGroupsWithMarkerGenes()Retrieve grouping variables for which marker genes were generated using a specified method.
Cerebro_v1.3$getGroupsWithMarkerGenes(method)
methodName of method.
vector of grouping variables for which marker genes were
calculated using the specified method.
getMarkerGenes()Retrieve table of marker genes for specific method and grouping variable.
Cerebro_v1.3$getMarkerGenes(method, name)
methodName of method.
nameName of table.
data.frame that contains marker genes for the specified
combination of method and grouping variable.
addEnrichedPathways()Add table of enriched pathways.
Cerebro_v1.3$addEnrichedPathways(method, name, table)
methodName of method that was used to generate the enriched pathways.
nameName of table. This name will be used to select the table in
Cerebro. It is recommended to use the grouping variable, e.g.
sample.
tabledata.frame that contains the enriched pathways.
getMethodsForEnrichedPathways()Retrieve names of methods that were used to generate enriched pathways.
Cerebro_v1.3$getMethodsForEnrichedPathways()
vector of names of methods that were used to generate enriched
pathways.
getGroupsWithEnrichedPathways()Retrieve grouping variables for which enriched pathways were generated using a specified method.
Cerebro_v1.3$getGroupsWithEnrichedPathways(method)
methodName of method.
vector of grouping variables for which enriched pathways were
calculated using the specified method.
getEnrichedPathways()Retrieve table of enriched pathways for specific method and grouping variable.
Cerebro_v1.3$getEnrichedPathways(method, name)
methodName of method.
nameGrouping variable.
data.frame that contains enriched pathways for the specified
combination of method and grouping variable.
addTrajectory()Add trajectory.
Cerebro_v1.3$addTrajectory(method, name, content)
methodName of method that was used to generate the trajectory.
nameName of the trajectory. This name will be used later in Cerebro to select the trajectory.
contentRelevant data for the trajectory, depending on the method
this could be a list holding edges, cell positions, pseudotime,
etc.
getMethodsForTrajectories()Retrieve names of methods that were used to generate trajectories.
Cerebro_v1.3$getMethodsForTrajectories()
vector of names of methods that were used to generate
trajectories.
getNamesOfTrajectories()Retrieve names of available trajectories for a specified method.
Cerebro_v1.3$getNamesOfTrajectories(method)
methodName of method.
vector of available trajectory for the specified method.
getTrajectory()Retrieve data for a specific trajectory.
Cerebro_v1.3$getTrajectory(method, name)
methodName of method.
nameName of trajectory.
The type of data depends on the method that was used to generate the trajectory.
addExtraMaterial()Add content to extra material field.
Cerebro_v1.3$addExtraMaterial(category, name, content)
categoryName of category. At the moment, only tables and
plots are valid categories. Tables must be in data.frame
format and plots must be created with ggplot2.
nameName of material, will be used to select it in Cerebro.
contentData that should be added.
addExtraTable()Add table to `extra_material` slot.
Cerebro_v1.3$addExtraTable(name, table)
nameName of material, will be used to select it in Cerebro.
tableTable that should be added, must be data.frame.
addExtraPlot()Add plot to `extra_material` slot.
Cerebro_v1.3$addExtraPlot(name, plot)
nameName of material, will be used to select it in Cerebro.
plotPlot that should be added, must be created with
ggplot2 (class: ggplot).
getExtraMaterialCategories()Get names of categories for which extra material is available.
Cerebro_v1.3$getExtraMaterialCategories()
vector with names of available categories.
checkForExtraTables()Check whether there are tables in the extra materials.
Cerebro_v1.3$checkForExtraTables()
logical indicating whether there are tables in the extra
materials.
getNamesOfExtraTables()Get names of tables in extra materials.
Cerebro_v1.3$getNamesOfExtraTables()
vector containing names of tables in extra materials.
getExtraTable()Get table from extra materials.
Cerebro_v1.3$getExtraTable(name)
nameName of table.
Requested table in data.frame format.
checkForExtraPlots()Check whether there are plots in the extra materials.
Cerebro_v1.3$checkForExtraPlots()
logical indicating whether there are plots in the extra
materials.
getNamesOfExtraPlots()Get names of plots in extra materials.
Cerebro_v1.3$getNamesOfExtraPlots()
vector containing names of plots in extra materials.
getExtraPlot()Get plot from extra materials.
Cerebro_v1.3$getExtraPlot(name)
nameName of plot.
Requested plot made with ggplot2.
print()Show overview of object and the data it contains.
Print overview of available marker gene results for self$print()
function.
Print overview of available enriched pathway results for
self$print() function.
Print overview of available trajectories for self$print() function.
Print overview of extra material for self$print() function.
Cerebro_v1.3$print()
clone()The objects of this class are cloneable with this method.
Cerebro_v1.3$clone(deep = FALSE)
deepWhether to make a deep clone.