% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/preprocessing.R
\name{tl_split}
\alias{tl_split}
\title{Split data into train and test sets}
\usage{
tl_split(data, prop = 0.8, stratify = NULL, seed = NULL)
}
\arguments{
\item{data}{A data frame}

\item{prop}{Proportion for training set (default: 0.8)}

\item{stratify}{Column name for stratified splitting}

\item{seed}{Random seed for reproducibility}
}
\value{
A list with two elements:
\describe{
\item{\code{$train}}{A data frame containing the training subset.}
\item{\code{$test}}{A data frame containing the test subset.}
}
}
\description{
Split data into train and test sets
}
\examples{
\donttest{
split_data <- tl_split(iris, prop = 0.7, stratify = "Species")
train <- split_data$train
test <- split_data$test
}
}
