powered by
Simulate data from the Friedman 1 benchmark problem. See mlbench.friedman1 for details and references.
mlbench.friedman1
gen_friedman1(n = 100, nx = 10, sigma = 0.1)
A data frame with n rows and nx + 1 columns (for nx features and the response).
n
nx
Integer specifying the number of samples (i.e., rows) to generate. Default is 100.
Integer specifying the number of predictor variables to generate. Default is 10. Note that nx >= 5.
nx >= 5
Numeric specifying the standard deviation of the standard Gaussian noise.
set.seed(2319) # for reproducibility friedman1 <- gen_friedman1(nx = 5) pairs(friedman1, col = "purple2")
Run the code above in your browser using DataLab