| caps {fdacluster} | R Documentation |
Class for clustering with amplitude and phase separation
Description
The k-means algorithm with joint amplitude and phase separation produces a
number of outputs. This class is meant to encapsulate them into a single
object for providing dedicated S3 methods for e.g. plotting, summarizing,
etc. The name of the class stems from Clustering with Amplitude and
Phase Separation.
Usage
as_caps(x)
is_caps(x)
Arguments
x |
A list coercible into an object of class |
Details
An object of class caps is a list with the following components:
-
original_curves: A numeric matrix of shapeN \times L \times Mstoring a sample with theNL-dimensional original curves observed on grids of sizeM. -
original_grids: A numeric matrix of sizeN \times Mstoring the grids of sizeMon which original curves are evaluated; -
aligned_grids: A numeric matrix of sizeN \times Mstoring the grids of sizeMon which original curves must be evaluated to be aligned; -
center_curves: A numeric matrix of shapeK \times L \times Mstoring theKcenters which areL-dimensional curves observed on a grid of sizeM; -
center_grids: A numeric matrix of sizeK \times Mstoring the grids of sizeMon which center curves are evaluated; -
warpings: A numeric matrix of shapeN \times Mstoring the estimated warping functions for each of theNcurves evaluated on the within-cluster commongridsof sizeM; -
n_clusters: An integer value storing the number of clusters; -
memberships: An integer vector of lengthNstoring the cluster ID which each curve belongs to; -
distances_to_center: A numeric vector of lengthNstoring the distance of each curve to the center of its cluster; -
silhouettes: A numeric vector of lengthNstoring the silhouette values of each observation; -
amplitude_variation: A numeric value storing the fraction of total variation explained by amplitude variability. -
total_variation: A numeric value storing the amount of total variation. -
n_iterations: An integer value storing the number of iterations performed until convergence; -
call_name: A string storing the name of the function that was used to produce the k-means alignment results; -
call_args: A list containing the exact arguments that were passed to the functioncall_namethat produced this output.
Value
The function as_caps() returns an object of class caps. The
function is_caps() returns a boolean which evaluates to TRUE is the
input object is of class caps.
Examples
as_caps(sim30_caps)
is_caps(sim30_caps)