% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/temperature.R
\name{ck_txn}
\alias{ck_txn}
\title{Annual or Monthly Minimum of Daily Maximum Temperature (TXn)}
\usage{
ck_txn(tmax, dates, period = "annual")
}
\arguments{
\item{tmax}{Numeric vector of daily maximum temperatures (degrees C).}

\item{dates}{Date vector of the same length as \code{tmax}.}

\item{period}{Character. Aggregation period: \code{"annual"} (default) or
\code{"monthly"}.}
}
\value{
A data frame with columns \code{period}, \code{value}, \code{index}, and \code{unit}.
}
\description{
ETCCDI canonical index TXn. The minimum value of daily maximum
temperature (Tmax) within each reporting period (coldest day).
}
\examples{
dates <- as.Date("2024-01-01") + 0:9
tmax <- c(5, 10, -3, 12, 4, 8, 22, -8, 7, 6)
ck_txn(tmax, dates)
}
