X-Git-Url: https://git.auder.net/?p=agghoo.git;a=blobdiff_plain;f=R%2FR6_Model.R;h=8fc232426ebaa0f0f2f1c06340a087df708e8012;hp=8912cdb47110d3e68c99815c6c48ceb1282027e6;hb=504afaadc783916dc126fb87ab9e067f302eb2c5;hpb=15f48abea9c631d52317ff157c8af0dd4c7a67d3 diff --git a/R/R6_Model.R b/R/R6_Model.R index 8912cdb..8fc2324 100644 --- a/R/R6_Model.R +++ b/R/R6_Model.R @@ -49,12 +49,17 @@ Model <- R6::R6Class("Model", }, #' @description #' Returns the model at index "index", trained on dataHO/targetHO. - #' index is between 1 and self$nmodels. #' @param dataHO Matrix or data.frame #' @param targetHO Vector of targets (generally numeric or factor) #' @param index Index of the model in 1...nmodels get = function(dataHO, targetHO, index) { private$gmodel(dataHO, targetHO, private$params[[index]]) + }, + #' @description + #' Returns the parameter at index "index". + #' @param index Index of the model in 1...nmodels + getParam = function(index) { + private$params[[index]] } ), private = list(