generate_pseudo_bulk_data | R Documentation |
generate_pseudo_bulk_data
generate_pseudo_bulk_data(
object,
group_by = NULL,
split_by = "random",
k_variable = 4
)
object |
The Seurat or SingleCellExperiment object to analyse. |
group_by |
entry in metadata table, based on these cluster annotation pseudo bulk is performed |
split_by |
variable -> split by a variable within the metadata; k must be a string random -> splits based on a random number; k must be a number Louvain, Louvain_multilevel, SLM, Leiden -> subclusters k must be a list with [resolution, cluster_1, cluster_2] |
k_variable |
variable dependent on the split_by |
returns pseudo bulk generated data
#using SCE object
library("scRNAseq")
SCE_OBJECT <- ZeiselBrainData()
# generating pseudo bulk data using the SCE object above,
# and clustering level level1class from the metadata
# generate pseudo bulk data based on random subsampling
SCE_RESULT_RANDOM <- generate_pseudo_bulk_data(SCE_OBJECT,
group_by = "level1class",
split_by = "random",
k_variable = 5)
# generate pseudo bulk data based on variable within the metadata
SCE_RESULT_VARIABLE <- generate_pseudo_bulk_data(SCE_OBJECT, "level1class","variable","tissue")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.