Skip to content

Commit 31ee5d8

Browse files
committed
remove tailor(time) (closes #16)
1 parent aac6b57 commit 31ee5d8

File tree

2 files changed

+4
-21
lines changed

2 files changed

+4
-21
lines changed

R/tailor.R

+3-12
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,18 @@
99
#' @param probabilities The names of class probability estimates (if any). For
1010
#' classification, these should be given in the order of the factor levels of
1111
#' the `estimate`.
12-
#' @param time The name of the predicted event time. (not yet supported)
1312
#' @examples
1413
#'
1514
#' tailor()
1615
#' @export
1716
tailor <- function(type = "unknown", outcome = NULL, estimate = NULL,
18-
probabilities = NULL, time = NULL) {
17+
probabilities = NULL) {
1918
columns <-
2019
list(
2120
outcome = outcome,
2221
type = type,
2322
estimate = estimate,
24-
probabilities = probabilities,
25-
time = time
23+
probabilities = probabilities
2624
)
2725

2826
new_tailor(
@@ -80,7 +78,7 @@ print.tailor <- function(x, ...) {
8078

8179
#' @export
8280
fit.tailor <- function(object, .data, outcome, estimate, probabilities = c(),
83-
time = c(), ...) {
81+
...) {
8482
# ------------------------------------------------------------------------------
8583
# set columns via tidyselect
8684

@@ -95,13 +93,6 @@ fit.tailor <- function(object, .data, outcome, estimate, probabilities = c(),
9593
check_selection(enquo(probabilities), columns$probabilities, "probabilities")
9694
}
9795

98-
time <- tidyselect::eval_select(enquo(time), .data)
99-
if (length(time) > 0) {
100-
columns$time <- names(time)
101-
} else {
102-
columns$time <- character(0)
103-
}
104-
10596
.data <- .data[, names(.data) %in% unlist(columns)]
10697
if (!tibble::is_tibble(.data)) {
10798
.data <- tibble::as_tibble(.data)

man/tailor.Rd

+1-9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)