% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/get_aapc.R
\name{get_aapc}
\alias{get_aapc}
\title{Average Annual Percent Change (AAPC)}
\usage{
get_aapc(mod, digits = 1, show_ci = TRUE, dec = ".")
}
\arguments{
\item{mod}{Joinpoint regression model (segmented object) or linear regression model (lm object).}

\item{digits}{Number of decimal places to display (integer).}

\item{show_ci}{Logical; if TRUE, displays the 95\% confidence interval.
If FALSE, displays significance stars.}

\item{dec}{Character. Decimal separator to use (e.g., "." or ",").}
}
\value{
A character string with the AAPC and either its 95\% confidence
interval or significance stars.
}
\description{
Estimates the Average Annual Percent Change (AAPC) and its 95\% confidence
interval. Optionally displays statistical significance using significance
stars.
}
\examples{
# Load example data
data("plant", package = "segmented")

names(plant)

# Fit the joinpoint models
mods <- model_jp(data = plant, value = "y", time = "time", group = "group", k = 2, test = TRUE)

# AAPC of the first model
get_aapc(mods$RKW, digits = 1, show_ci = TRUE, dec = ".")
}
\author{
Tamara Ricardo
}
