fuzzygene_context {FuzzyGene} R Documentation

Inject a transcriptome context as the initial condition of the virtual perturbation.

Description

Usage

fuzzygene_context(fuzzygene, context,
    valueColumn = NULL,
    minCoverage = 0,
    align = NULL);

Arguments

fuzzygene

a trained model. [as FuzzyGeneModel]

context

the context table path (csv/tsv) with a gene column and an expression column

valueColumn

the name of the expression column; empty uses the last column of the table. [as string]

minCoverage

the minimum fraction (0-1) of model genes that must be covered by the table, 0 disables the check. [as double]

env

the R# runtime environment used to report errors. [as Environment]

Details

The context replaces the control baseline: both the wildtype and the mutant state are propagated from the given condition, so foldchange is read as "mutant vs wildtype inside this context" instead of "mutant vs the training mean".

The table (csv or tsv) must carry at least one gene column and one expression column. All non-numeric columns are treated as candidate gene keys and the one that matches the most model genes is used, so a gene_name,gene_id,mean_counts pseudobulk table works out of the box. Rows whose expression value is not a finite number are skipped (never silently turned into zero), and model genes that are absent from the table keep the training baseline.

Note that a fitted static map is usually contractive: after it converges, the state no longer depends on where the propagation started. The context therefore matters most for (i) the reference state used by fold changes, (ii) non-converged / transient responses and (iii) lagged (time series) models.

Authors

biosystem

Value

a multi line coverage summary, or an R# error object when the context is rejected

clr value class

Examples


[Package FuzzyGene version 1.0.0.0 Index]