plotCluster: Plot trajectories based on clustering

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/plotCluster.R

Description

Draw trajectories and are colored based on their clusters

Usage

1
plotCluster(data, clust, ncluster, ...)

Arguments

data

Numeric data frame or matrix with de original data. SummarizedExperiment object can be provided for compatibility with bioconductor container (for more information see vignette).

clust

Object of class pam or partition obtained from getClusters output.

ncluster

When nclust = 'all', plots all trajectories and cluster together in a single plot. If it's an integer, it draws only trajectories that belong to that cluster. Finally, if it is a numeric vector, it draws trajectories corresponding to each cluster within a subplot.

...

Other arguments to pass to importFromSE if _x_ is SummarizedExperiment-class.

Details

It draws trajectories where x axis is time data and y axis trayectory values.

Value

Plot clustered trayectories

Author(s)

Fernando Pérez-Sanz (fernando.perez8@um.es)

Miriam Riquelme-Pérez (miriam.riquelmep@gmail.com)

See Also

matplot, plotClusterSenator, importFromSE.

Examples

1
2
3
4
5
6
data(tscR)
data <- tscR
time <- c(1,2,3)
fdist <- frechetDistC(data, time)
fclust <- getClusters(fdist, 3)
plotCluster(data, fclust, 'all')

tscR documentation built on Nov. 8, 2020, 5:53 p.m.