% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/core.R
\name{predict.tidylearn_model}
\alias{predict.tidylearn_model}
\title{Predict using a tidylearn model}
\usage{
\method{predict}{tidylearn_model}(object, new_data = NULL, type = "response", ...)
}
\arguments{
\item{object}{A tidylearn model object}

\item{new_data}{A data frame containing the new data.
If NULL, uses training data.}

\item{type}{Type of prediction. For supervised:
"response" (default), "prob", "class". For
unsupervised: "scores", "clusters", "transform"
depending on method.}

\item{...}{Additional arguments}
}
\value{
A \link[tibble]{tibble} with a \code{.pred} column containing
predictions. For classification with \code{type = "prob"}, returns
columns for each class probability.
}
\description{
Unified prediction interface for both supervised and unsupervised models
}
\examples{
\donttest{
model <- tl_model(mtcars, mpg ~ wt + hp, method = "linear")
predict(model)
predict(model, new_data = mtcars[1:5, ])
}
}
