calculate_cluster_profile: Calculate mean profile of an isoform cluster

calculate_cluster_profileR Documentation

Calculate mean profile of an isoform cluster

Description

This function computes mean cluster expression across all isoforms, as well as the standard deviation. First, cell type-level mean expression is computed for each isoform. Then, the average value of all cell type means is computed across isoforms.

Usage

calculate_cluster_profile(data, isoform_ids, id_table, isoform_col = NULL)

Arguments

data

A data.frame or tibble including single-cell data, with isoforms as rows and cells as columns. Isoform IDs can be included as row names (data.frame) or as an additional column (tibble). Expression should be previously scaled (see scale_range).

isoform_ids

A character vector including the IDs of the isoforms included in the cluster.

id_table

A data frame including two columns named cell and cell_type, providing the correspondence between cell ID and cell type should be provided. The number of rows should be equal to the total number of cell columns in data, and the order of the cell column should match column (i.e. cell) order in data.

isoform_col

When a tibble is provided in data, a character object indicating the name of the column where isoform IDs are specified. Otherwise, isoform identifiers will be assumed to be defined as rownames, and this argument will not need to be provided.

Value

A tibble including three main columns: cell type name, global cluster mean expression in each cell type, and standard deviation computed for the cell type mean expression of all isoforms.


ConesaLab/acorde documentation built on Feb. 25, 2024, 4:16 a.m.