predicted_draws.lbart: Get predict draws from posterior of 'lbart' model

View source: R/tidy-posterior-BART.R

predicted_draws.lbartR Documentation

Get predict draws from posterior of lbart model

Description

Get predict draws from posterior of lbart model

Usage

## S3 method for class 'lbart'
predicted_draws(
  object,
  newdata,
  value = ".prediction",
  ...,
  ndraws = NULL,
  include_newdata = TRUE
)

Arguments

object

A lbart model.

newdata

Data frame to generate predictions from. If omitted, most model types will generate predictions from the data used to fit the model.

value

The name of the output column for predicted_draws; default ".prediction".

...

Use to specify random number generator, default is rng=stats::rnorm.

ndraws

Not currently implemented.

include_newdata

Should the newdata be included in the tibble?

Value

A tidy data frame (tibble) with predicted values.


bonStats/tidytreatment documentation built on Jan. 16, 2025, 6:16 a.m.