View source: R/bart_package_summaries.R
print.bartMachine | R Documentation |
bartMachine
object.
This is an alias for the summary.bartMachine
function. See description in that section.
## S3 method for class 'bartMachine'
print(x, ...)
x |
An object of class “bartMachine”. |
... |
Parameters that are ignored. |
None.
Adam Kapelner and Justin Bleich
## Not run:
#Regression example
#generate Friedman data
set.seed(11)
n = 200
p = 5
X = data.frame(matrix(runif(n * p), ncol = p))
y = 10 * sin(pi* X[ ,1] * X[,2]) +20 * (X[,3] -.5)^2 + 10 * X[ ,4] + 5 * X[,5] + rnorm(n)
##build BART regression model
bart_machine = bartMachine(X, y)
##print out details
print(bart_machine)
##Also, the default print works too
bart_machine
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.