Either number of parameters or sum over parameter lengths.
getParamNr(par.set, devectorize = FALSE)
par.set | ParamSet |
---|---|
devectorize | ( |
ps = makeParamSet( makeNumericParam("u"), makeDiscreteVectorParam("x", len = 2, values = c("a", "b")) ) getParamNr(ps)#> [1] 2getParamNr(ps, devectorize = TRUE)#> [1] 3