Cycle-class {RPointCloud}R Documentation

Cycle Objects For Visualizing Topological Data Analysis Results

Description

The Cycle object represents a cycle found by performing topological data analysis (using the TDA package) on a data matrix or distance matrix.

Usage

Cycle(rips, dimen, J, color)
getCycle(rips, dimension = 1, target = NULL)
cycleSupport(cycle, view)
## S4 method for signature 'Cycle,matrix'
plot(x, y, lwd = 2, ...)
## S4 method for signature 'Cycle'
lines(x, view, ...)

Arguments

rips

A Rips diagram from the TDA package.

dimen

An integer; the dimension of the cycle.

J

An integer; the index locating the cycle in the cycleLocation portion of the Rips diagram. If NULL, then looks for the most persistent cycle.

color

A character vector of length one; the color in which to display the cycle.

x

A Cycle object.

y

A (layout) matrix with coordinates showing where to plot each point supporting the cycle.

view

A (layout) matrix with coordinates showing where to plot each point supporting the cycle.

lwd

A number; the graphical line width parameter lwd.

...

The usual set of additional graphical parameters.

dimension

An integer; the dimension of the cycle.

target

An integer indexing the desired cycle. Note that the index should be relative to other cuycles of the same dimension. If NULL, gets the longest persisting cycle.

cycle

A raw cycle, meaning a simple element of the cycleLocation part of a Rips diagram.

Value

The Cycle function constructs and returns an object of the Cycle class

The plot and lines methods return (invisibly) the Cycle object that was their first argument.

The getCycle function extracts a single raw cycle from a Rips diagram and returns it. The cycleSupport function combines such a cycle with a layout/view matrix to extract a list of the coordinates of the points contained in the cycle.

Slots

index:

A matrix, containing the indices into the data matrix or distance matrix defining the simplices that realize the cycle.

dimension:

A matrix; the dimension of the cycle.

color:

A character vector; the color in which to display the cycle.

Methods

plot(x, y, lwd = 2, ...):

Produce a plot of a Cycle object.

lines(x, view, ...)

Add a depiction of a cycle to an existing plot.

Author(s)

Kevin R. Coombes <krc@silicovore.com>

See Also

TDA, ripsDiag

Examples

data(CLL)
cyc1 <- Cycle(ripdiag, 1, 236, "forestgreen")
V <- cmdscale(daisydist)
plot(cyc1, V)
plot(V, pch = 16, col = "gray")
lines(cyc1, V)

[Package RPointCloud version 0.6.2 Index]