Get fitted values for each cell.

predictCells(models, ...)

# S4 method for SingleCellExperiment
predictCells(models, gene)

# S4 method for list
predictCells(models, gene)

Arguments

models

Either the SingleCellExperiment object obtained after running fitGAM, or the specific GAM model for the corresponding gene, if working with the list output of tradeSeq.

...

parameters including:

gene

Gene name of gene for which to extract fitted values.

Value

A vector of fitted values.

Details

Using the gene expression model of tradeSeq available at https://www.nature.com/articles/s41467-020-14766-3#Sec2. the output of predictCells returns the \(\eta_{gi}\) value for each cell.

Examples

data(gamList, package = "tradeSeq") predictCells(models = gamList, gene = 1)
#> [,1] [,2] [,3] [,4] [,5] [,6] #> 1 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 #> [,7] [,8] [,9] [,10] [,11] [,12] #> 1 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16 #> [,13] [,14] [,15] [,16] #> 1 2.220446e-16 2.220446e-16 2.220446e-16 2.220446e-16