ExposureFuzzyClustering: Fuzzy Clustering of exposure data

FuzzyClustExpR Documentation

Fuzzy Clustering of exposure data

Description

FuzzyClustExp : Performs fuzzy C-means clustering of samples, based on exposures. The number of clusters is defined by optimizing the PBMF index of obtained clustering.

Usage

## S4 method for signature 'SignExp,numeric'
FuzzyClustExp(signexp_obj, max_instances=200, Clim,
                method.dist="euclidean", method.clust="fcm", relative=FALSE, 
                m=2, plot_to_file=FALSE, file="FuzzyClustExp.pdf",colored=TRUE)

Arguments

signexp_obj

a SignExp object returned by signeR function.

max_instances

Maximum number of the exposure matrix instances to be analyzed. If the number of available E instances is bigger than this parameter, a subset of those will be randomly selected for analysis.

Clim

number of groups range, a vector with minimum and maximum accepted number of groups. The algorithm will maximize the PBMF-index within this range.

method.dist

used distance metric

method.clust

clustering method. Either "fcm", default, for fuzzy C-means or "km" for k-means.

relative

Whether to normalize exposures of each sample so that they sum up to one. Default is FALSE, thus clustering samples by the absolute contributions of signatures to mutation counts. Otherwise, clustering will be based on relative contributions.

m

Expoent used in PBMF-index

plot_to_file

Whether to save a heatmap of results to the file parameter. Default is FALSE.

file

Output file to export a heatmap with the levels of pertinence of samples to found groups.

colored

Whether plots will be in color or B&W. Default is TRUE.

Value

A list with the following items: Meanfuzzy=Meanfuzzy, AllFuzzy=Fuzzy[[1]], Centroids=Fuzzy[[2]]

Meanfuzzy

Final clustering: mean levels of pertinence of samples to found groups.

AllFuzzy

All levels of pertinence of samples to found groups in repeated runs of the clustering algorithm.

Centroids

All centroids of found groups in repeated runs of the clustering algorithm.

Examples

# assuming signatures is the return value of signeR()

# Limits to number of groups:
cl <- c(2,4)

FuzClust <- FuzzyClustExp(signatures$SignExposures, Clim = cl)

# see also
vignette(package="signeR")

rvalieris/signeR documentation built on April 20, 2024, 2:08 p.m.