% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ppmodel.R
\name{weighted_importance}
\alias{weighted_importance}
\title{Weighted projection variable importance for a random forest.}
\usage{
weighted_importance(model)
}
\arguments{
\item{model}{A \code{pprf} forest model.}
}
\value{
A non-negative numeric vector, one entry per feature.
}
\description{
Weights each tree's projection-based importance by a per-tree OOB
quality score — `1 - error_rate` in `[0, 1]` for classification, and
`max(0, 1 - NMSE)` in `[0, 1]` for regression — then aggregates
`I_s × |a_j|` over splits. Computed lazily from the training data
stored on the model; the result is cached.
}
\details{
**Sign semantics.** Entries are non-negative by construction (weights
and per-split contributions are both non-negative). A zero entry means
"this feature never appeared in a weighted OOB-contributing split,"
not "within noise." Contrast with \code{\link{permuted_importance}},
where negative values are meaningful. Do not re-normalize — rely on
the ranking.
}
