collapseMotifMatrix.RdCollapse TF motif matrix of arbitrary values by aggregating values over motif cluster assignment
collapseMotifMatrix(
X,
motifClust = NULL,
assembly = "hg38",
motifs = "jaspar",
aggrFun = mean
)matrix to be collapsed. Must have the motif names as rownames. E.g. matrix obtained by chromVAR::deviationScores
optional: motif clustering computed by getMotifClustering. If NULL (default) the default clustering will be retrieved
genome assembly for which the motif clustering should be retrieved. Only required if for automatic mode (i.e. motifClust=NULL).
a character string specifying the motif set (currently only "jaspar" is supported)
function to use to aggregate values
list containing two elements: X: Collapsed matrix containing motif cluster aggregated values;
clustering: clustering result used for aggregation (seegetMotifClustering for details)