| alphaComplexDiag {TDA} | R Documentation | 
Alpha Complex Persistence Diagram
Description
The function alphaComplexDiag computes the persistence diagram of the alpha complex filtration built on top of a point cloud.
Usage
alphaComplexDiag(
    X, maxdimension = NCOL(X) - 1, library = "GUDHI",
	location = FALSE, printProgress = FALSE)
Arguments
| X | an  | 
| maxdimension | integer: max dimension of the homological features to be computed. (e.g. 0 for connected components, 1 for connected components and loops, 2 for connected components, loops, voids, etc.) | 
| library | either a string or a vector of length two. When a vector is given, the first element specifies which library to compute the Alpha Complex filtration, and the second element specifies which library to compute the persistence diagram. If a string is used, then the same library is used. For computing the Alpha Complex filtration, the user can use the library  | 
| location | if  | 
| printProgress | if  | 
Details
The function alphaComplexDiag constructs the Alpha Complex filtration, using the C++ library GUDHI.
Then for computing the persistence diagram from the Alpha Complex filtration, the user can use either the C++ library GUDHI, Dionysus, or PHAT.
See refereneces.
Value
The function alphaComplexDiag returns a list with the following elements:
| diagram | an object of class  | 
| birthLocation | only if  | 
| deathLocation | only if  | 
| cycleLocation | only if  | 
Author(s)
Jisu Kim and Vincent Rouvreau
References
Edelsbrunner H, Harer J (2010). "Computational topology: an introduction." American Mathematical Society.
Rouvreau V (2015). "Alpha complex." In GUDHI User and Reference Manual. GUDHI Editorial Board. https://gudhi.inria.fr/doc/latest/group__alpha__complex.html
Edelsbrunner H, Kirkpatrick G, Seidel R (1983). "On the shape of a set of points in the plane." IEEE Trans. Inform. Theory.
Maria C (2014). "GUDHI, Simplicial Complexes and Persistent Homology Packages." https://project.inria.fr/gudhi/software/
See Also
summary.diagram, plot.diagram, alphaShapeDiag, gridDiag, ripsDiag
Examples
# input data generated from a circle
X <- circleUnif(n = 30)
# persistence diagram of alpha complex
DiagAlphaCmplx <- alphaComplexDiag(
    X = X, library = c("GUDHI", "Dionysus"), location = TRUE,
    printProgress = TRUE)
# plot
par(mfrow = c(1, 2))
plot(DiagAlphaCmplx[["diagram"]])
one <- which(DiagAlphaCmplx[["diagram"]][, 1] == 1)
one <- one[which.max(
    DiagAlphaCmplx[["diagram"]][one, 3] - DiagAlphaCmplx[["diagram"]][one, 2])]
plot(X, col = 2, main = "Representative loop of data points")
for (i in seq(along = one)) {
  for (j in seq_len(dim(DiagAlphaCmplx[["cycleLocation"]][[one[i]]])[1])) {
    lines(
        DiagAlphaCmplx[["cycleLocation"]][[one[i]]][j, , ], pch = 19, cex = 1,
        col = i)
  }
}
par(mfrow = c(1, 1))