diff --git a/R/PipeOpFFS.R b/R/PipeOpFFS.R index e636d2a..9f3b039 100644 --- a/R/PipeOpFFS.R +++ b/R/PipeOpFFS.R @@ -22,6 +22,7 @@ #' If the element if is function it requires the following arguments: `arg` and `value` and returns a `numeric`. #' For string elements, the following predefined features are available: #' `"mean"`, `"max"`,`"min"`,`"slope"`,`"median"`,`"var"`. +#' Initial is `c("mean", "max", "min", "slope", "median", "var")` #' * `left` :: `numeric()` \cr #' The left boundary of the window. Initial is `-Inf`. #' The window is specified such that the all values >=left and <=right are kept for the computations. @@ -106,7 +107,8 @@ PipeOpFFS = R6Class("PipeOpFFS", param_set$set_values( drop = FALSE, left = -Inf, - right = Inf + right = Inf, + features = c("mean", "max", "min", "slope", "median", "var") ) super$initialize( diff --git a/R/TaskRegr_dti.R b/R/TaskRegr_dti.R index 229429d..64ee5bb 100644 --- a/R/TaskRegr_dti.R +++ b/R/TaskRegr_dti.R @@ -8,7 +8,7 @@ #' to predict the PASAT score. `pasat` represents the PASAT score at each vist. #' `subject_id` represents the subject ID. `cca` represents the fractional anisotropy tract profiles from the corpus #' callosum. `sex` indicates subject's sex. `rcst` represents the fractional anisotropy tract profiles from the right -#' corticospinal tract. `case` indicates wether the subject has multiple sclerosis. Rows with NAs are removed. +#' corticospinal tract. `Rows with NAs are removed. #' #' #' This is a subset of the full dataset, which is contained in the package `refund`. diff --git a/R/zzz.R b/R/zzz.R index 9f3f10d..1cedab7 100644 --- a/R/zzz.R +++ b/R/zzz.R @@ -35,7 +35,7 @@ named_union = function(x, y) { set_names(z, union(names(x), names(y))) } -mlr3fda_feature_types = c(f_reg = "tfd_reg", f_irreg = "tfd_irreg") +mlr3fda_feature_types = c(tfr = "tfd_reg", tfi = "tfd_irreg") mlr3fda_tasks = new.env() mlr3fda_pipeops = new.env() diff --git a/README.md b/README.md index e6da287..e7057dd 100644 --- a/README.md +++ b/README.md @@ -58,7 +58,7 @@ mlr_reflections$task_feature_types ## lgl int dbl chr fct ord ## "logical" "integer" "numeric" "character" "factor" "ordered" - ## pxc f_reg f_irreg + ## pxc tfr tfi ## "POSIXct" "tfd_reg" "tfd_irreg" The newly available data types are: @@ -83,7 +83,7 @@ task ## * Target: heatan ## * Properties: - ## * Features (3): - ## - f_reg (2): NIR, UVVIS + ## - tfr (2): NIR, UVVIS ## - dbl (1): h20 Currently there are no `Learner`s that directly operate on functional diff --git a/data-raw/dti.R b/data-raw/dti.R index cf408fc..23f2663 100644 --- a/data-raw/dti.R +++ b/data-raw/dti.R @@ -6,8 +6,7 @@ dti = data.table( pasat = refund::DTI$pasat, cca = tfd(refund::DTI$cca, arg = seq(0, 1, l = 93)), rcst = tfd(refund::DTI$rcst, arg = seq(0, 1, l = 55)), - sex = refund::DTI$sex, - case = factor(ifelse(refund::DTI$case, "MS", "control")) + sex = refund::DTI$sex ) dti = na.omit(dti) diff --git a/data/dti.rda b/data/dti.rda index f325f09..39683a3 100644 Binary files a/data/dti.rda and b/data/dti.rda differ diff --git a/man/mlr_pipeops_ffs.Rd b/man/mlr_pipeops_ffs.Rd index 7a1f4f2..15d6df5 100644 --- a/man/mlr_pipeops_ffs.Rd +++ b/man/mlr_pipeops_ffs.Rd @@ -27,6 +27,7 @@ A list of features to extract. Each element can be either a function or a string If the element if is function it requires the following arguments: \code{arg} and \code{value} and returns a \code{numeric}. For string elements, the following predefined features are available: \code{"mean"}, \code{"max"},\code{"min"},\code{"slope"},\code{"median"},\code{"var"}. +Initial is \code{c("mean", "max", "min", "slope", "median", "var")} \item \code{left} :: \code{numeric()} \cr The left boundary of the window. Initial is \code{-Inf}. The window is specified such that the all values >=left and <=right are kept for the computations. diff --git a/man/mlr_tasks_dti.Rd b/man/mlr_tasks_dti.Rd index 66709a7..8511b25 100644 --- a/man/mlr_tasks_dti.Rd +++ b/man/mlr_tasks_dti.Rd @@ -11,7 +11,7 @@ This dataset contains two functional covariates and three scalar covariate. The to predict the PASAT score. \code{pasat} represents the PASAT score at each vist. \code{subject_id} represents the subject ID. \code{cca} represents the fractional anisotropy tract profiles from the corpus callosum. \code{sex} indicates subject's sex. \code{rcst} represents the fractional anisotropy tract profiles from the right -corticospinal tract. \code{case} indicates wether the subject has multiple sclerosis. Rows with NAs are removed. +corticospinal tract. `Rows with NAs are removed. This is a subset of the full dataset, which is contained in the package \code{refund}. }