The code section #### ESTIMATE TF ACTIVITY WITH DECOUPLER #### will use the DE stats computed or provided and output an estimation of differential TF activity. The argument 'statistics' details the statistical method to be used. It is recommended to use the multivariate linear model ("mlm") method, as this displayed the best performance in Perez 2024 and also is the fastest method - if so, leave the code as it is.
However if you wish to use other statistical methods, modify the argument as appropriate. Multiple methods can be specified as a vector or strings. If you use multiple methods, you can calculate a consensus score which integrates the results by specifying 'consensus_score = TRUE'. E.g:
DEdata_decouple <- decoupleR::decouple(
mat = DE_stats[, 1, drop = FALSE],
statistics = c("mlm", "ulm", "wsum"),
args = list(mlm = list(.mor = "weight")),