solve.Ensemble: Run the Ensemble Solver

Description Usage Arguments Value See Also Examples

Description

Given a TReNA object with Ensemble as the solver and a list of solvers (default = "default.solvers"), estimate coefficients for each transcription factor as a predictor of the target gene's expression level. The final scores for the ensemble method combine all specified solvers to create a composite score for each transcription factor. This method should be called using the solve method on an appropriate TReNA object.

Usage

1
2
3
## S4 method for signature 'EnsembleSolver'
run(obj, target.gene, tfs, tf.weights = rep(1,
  length(tfs)), extraArgs = list())

Arguments

obj

An object of class Solver with "ensemble" as the solver string

target.gene

A designated target gene that should be part of the mtx.assay data

tfs

The designated set of transcription factors that could be associated with the target gene

tf.weights

A set of weights on the transcription factors (default = rep(1, length(tfs)))

extraArgs

Modifiers to the Ensemble solver, including "solver.list", "gene.cutoff", and solver-named arguments denoting extraArgs that correspond to a given solver (e.g. "lasso")

Value

A data frame containing the scores for all solvers and two composite scores relating the target gene to each transcription factor. The two new scores are:

See Also

EnsembleSolver

Other solver methods: run,BayesSpikeSolver-method, run,LassoPVSolver-method, run,LassoSolver-method, run,PearsonSolver-method, run,RandomForestSolver-method, run,RidgeSolver-method, run,SpearmanSolver-method, run,SqrtLassoSolver-method, solve,TReNA-method

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# Load included Alzheimer's data, create a TReNA object with LASSO as solver, and solve
load(system.file(package="TReNA", "extdata/ampAD.154genes.mef2cTFs.278samples.RData"))
trena <- TReNA(mtx.assay = mtx.sub, solver = "ensemble")
target.gene <- "MEF2C"
tfs <- setdiff(rownames(mtx.sub), target.gene)
tbl <- solve(trena, target.gene, tfs)

# Solve the same problem, but supply extra arguments that change alpha for LASSO to 0.8 and also
# Change the gene cutoff from 10% to 20%
tbl <- solve(trena, target.gene, tfs, extraArgs = list("gene.cutoff" = 0.2, "lasso" = list("alpha" = 0.8)))

# Solve the original problem with default cutoff and solver parameters, but use only 4 solvers
tbl <- solve(trena, target.gene, tfs, extraArgs = list("solver.list" = c("lasso", "randomForest", "pearson", "bayesSpike")))

TReNA documentation built on Nov. 17, 2017, 12:35 p.m.