Skip to content

Commit

Permalink
- feat: Print column roles space, time or plot in Task (#198)
Browse files Browse the repository at this point in the history
print column roles `space`, `time` or `plot` in Task
  • Loading branch information
pat-s committed Jun 8, 2022
1 parent 3193af9 commit 75d4849
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions R/TaskRegrST.R
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,16 @@ TaskRegrST = R6::R6Class("TaskRegrST",
super$print(...)
cat("* Coordinates:\n")
print(self$coordinates())
if (length(self$col_roles$time) && length(self$col_roles$space)) {
cat("* Column roles:\n- Time:", self$col_roles$time,
"\n- Space:", self$col_roles$space, "\n")
} else if (length(self$col_roles$time)) {
cat("* Column roles:\n- Time:", self$col_roles$time, "\n")
} else if (length(self$col_roles$space)) {
cat("* Column roles:\n- Space:", self$col_roles$space, "\n")
} else if (length(self$col_roles$plot)) {
cat("* Column roles:\n- Plot:", self$col_roles$plot, "\n")
}
},

#' @field extra_args (named `list()`)\cr
Expand Down

0 comments on commit 75d4849

Please sign in to comment.