% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/pep_class.R
\name{new_pep}
\alias{new_pep}
\title{Create a PEP725 Phenological Data Object}
\usage{
new_pep(x, validate = TRUE)
}
\arguments{
\item{x}{A data.frame or data.table containing PEP725 phenological data.}

\item{validate}{Logical. If \code{TRUE} (default), validates that required
columns are present and have correct types.}
}
\value{
An object of class \code{c("pep", "data.table", "data.frame")}.
}
\description{
Constructor function that creates a validated \code{pep} object from a
data.frame or data.table. The object inherits from \code{data.table} and
retains all its functionality.
}
\details{
Required columns:
\itemize{
\item \code{s_id} - Station ID
\item \code{lon}, \code{lat} - Coordinates
\item \code{genus}, \code{species} - Plant taxonomy
\item \code{phase_id} - BBCH phenological phase code
\item \code{year}, \code{day} - Observation timing
}
}
\examples{
\donttest{
# From imported data
dt <- pep_download()
pep_data <- new_pep(dt)
}

}
\author{
Matthias Templ
}
