generateSampleShifts: Simulate sample shifts for each cell state

Description Usage Arguments Value

View source: R/generatePCs.R

Description

This function generates linear shifts in each samplefor each cell state. These shifts contribute to the adjusted centroid that is used for simulating PC locations

Usage

1
generateSampleShifts(sample_list, sample_vars, s_scale)

Arguments

sample_list

A named list of the sample names e.g. sample1, sample2, etc.

sample_vars

A matrix containing the sample_associated variance for each cell state in each PC. These are obtained as output from the "estimatePCVar" function.

s_scale

The magnitude of sample-associated gene expression variation the simulated dataset will exhibit. Setting s_scale = 1 will result in realistic levels of sample-associated variation (as derived from parameter estimation of the input dataset). Increasing s_scale results in higher variation, while decreasing s_scale results in lower variation.

Value

Returns a matrix containing the sample shift for each cell state in each PC


immunogenomics/scpost documentation built on July 28, 2021, 4:03 a.m.