# NOT RUN {
library(plot3D)
fn = makeRastriginFunction(dimensions = 2L)
# }
# NOT RUN {
# use the plot3D::persp3D method (default behaviour)
plot3D(fn)
plot3D(fn, contour = TRUE)
plot3D(fn, image = TRUE, phi = 30)
# use plotly::plot_ly for interactive plot
plot3D(fn, method = "plotly")
# }
Run the code above in your browser using DataLab