% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/simplicial.R
\name{persistent_homology}
\alias{persistent_homology}
\title{Persistent Homology}
\usage{
persistent_homology(x, n_steps = 20L, max_dim = 3L)
}
\arguments{
\item{x}{A square matrix, \code{tna}, or \code{netobject}.}

\item{n_steps}{Number of filtration steps (default 20).}

\item{max_dim}{Maximum simplex dimension to track (default 3).}
}
\value{
A \code{persistent_homology} object with:
\describe{
\item{betti_curve}{Data frame: \code{threshold}, \code{dimension},
\code{betti} at each filtration step.}
\item{persistence}{Data frame of birth-death pairs:
\code{dimension}, \code{birth}, \code{death}, \code{persistence}.}
\item{thresholds}{Numeric vector of filtration thresholds.}
}
}
\description{
Computes persistent homology by building simplicial complexes at
decreasing weight thresholds and tracking the birth/death of
topological features.
}
\examples{
mat <- matrix(c(0,.6,.5,.6,0,.4,.5,.4,0), 3, 3)
colnames(mat) <- rownames(mat) <- c("A","B","C")
ph <- persistent_homology(mat, n_steps = 10)
print(ph)

}
