gen_friedman1: Friedman benchmark data

View source: R/gen_friedman1.R

gen_friedman1R Documentation

Friedman benchmark data

Description

Simulate data from the Friedman 1 benchmark problem. See mlbench.friedman1 for details and references.

Usage

gen_friedman1(n = 100, nx = 10, sigma = 0.1)

Arguments

n

Integer specifying the number of samples (i.e., rows) to generate. Default is 100.

nx

Integer specifying the number of predictor variables to generate. Default is 10. Note that nx >= 5.

sigma

Numeric specifying the standard deviation of the standard Gaussian noise.

Value

A data frame with n rows and nx + 1 columns (for nx features and the response).

Examples

set.seed(2319)  # for reproducibility
friedman1 <- gen_friedman1(nx = 5)
pairs(friedman1, col = "purple2")

bgreenwell/treemisc documentation built on Oct. 26, 2022, 12:56 a.m.