ripser: Calculate Persistent Homology of a Point Cloud

Description Usage Arguments Value Examples

View source: R/ripser_func.R

Description

The 'mat' parameter should be a numeric matrix with each row corresponding to a single point, and each column corresponding to a single dimension. Thus, if 'mat' has 50 rows and 5 columns, it represents a point cloud with 50 points in 5 dimensions.

Usage

1
ripser(mat)

Arguments

mat

numeric matrix containing point cloud

Value

3-column matrix, with each row representing a TDA feature

Examples

1
2
3
4
5
6
7
# create a 2-d point cloud of a circle (100 points)
num.pts <- 100
rand.angle <- runif(num.pts, 0, 2*pi)
pt.cloud <- cbind(cos(rand.angle), sin(rand.angle))

# calculate persistent homology (num.pts by 3 numeric matrix)
pers.hom <- ripser(pt.cloud)

rrrlw/ripserr documentation built on July 30, 2018, 11:14 p.m.