Skip to content

Commit 0fbe7d8

Browse files
committed
update prepare CRAN
1 parent cc49ddb commit 0fbe7d8

12 files changed

+8
-32
lines changed

NAMESPACE

+1-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ export(create_model)
2222
export(create_vocabulary)
2323
export(evaluate)
2424
export(fit)
25-
export(get_task)
26-
export(get_vocabulary)
2725
export(max_case_length)
2826
export(num_outputs)
2927
export(predict)
@@ -35,6 +33,7 @@ export(vocab_size)
3533
import(bupaR)
3634
import(dplyr)
3735
import(eventdataR)
36+
import(ggplot2)
3837
import(keras)
3938
import(tensorflow)
4039
import(tidyr)

R/create_vocabulary.R

-5
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,6 @@
1010
#'
1111
#' @inheritParams tokenize
1212
#'
13-
#' @examples
14-
#' library(eventdataR)
15-
#' tasks <- c("outcome", "next_activity", "next_time", "remaining_time", "remaining_trace")
16-
#' purrr::map(tasks, ~prepare_examples_dt(patients, task = .x)) %>% purrr::map(create_vocabulary)
17-
#'
1813
#' @export
1914
create_vocabulary <- function(processed_df) {
2015

R/prepare_examples_df.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#' @param log \code{\link{log}}: Object of class \code{\link{log}} or derivatives (\code{\link{grouped_log}}, \code{\link{eventlog}},
77
#' \code{\link{activitylog}}, etc.).
88
#' @param task [`character`]: a process monitoring task for which to prepare an event log.
9-
#' @param features [`character`] (default [`NULL`]): additional features. Appends attributes (if present) [numeric_features] and/or [categorical_features] to a preprocessed event log.
9+
#' @param features [`character`] (default [`NULL`]): additional features. Appends attributes (if present) numeric_features and/or categorical_features to a preprocessed event log.
1010
#' @param ... additional arguments
1111
#'
1212
#' @return a preprocessed dataset

R/processpredictR.R

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
#' @importFrom cli cli_abort
1919
#' @importFrom glue glue
2020
#' @importFrom plotly ggplotly
21+
#' @import ggplot2
2122

2223

2324

R/stack_layers.R

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#'
33
#' User friendly interface to add a keras layer on top of existing model.
44
#'
5-
#' @param object [`ppred_model`]: a list containing a model
5+
#' @param object a list containing a model returned by create_model().
66
#' @param ... functions for adding layers by using functional keras API. For example, keras::layer_dense(units=32, activation="relu")
77
#'
88
#' @export

R/tokenize.R

-5
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@
66
#'
77
#' @return A list of tokens: token_x and token_y
88
#'
9-
#' @examples
10-
#' library(eventdataR)
11-
#' ex_remaining_trace <- prepare_examples(patients, task = "remaining_trace")
12-
#' tokenize(ex_remaining_trace, vocabulary = create_vocabulary(ex_remaining_trace))
13-
#'
149
#' @export
1510
tokenize <- function(processed_df) {
1611
UseMethod("tokenize")

R/utils.R

+1-3
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,13 @@
33

44
#' Utils
55
#'
6-
#' @param examples [`ppred_examples_df`]: a preprocessed dataset returned by prepare_examples_dt().
6+
#' @param examples a preprocessed dataset returned by prepare_examples_dt().
77
#'
8-
#' @export
98
#'
109
get_vocabulary <- function(examples) {
1110
attr(examples, "vocabulary")
1211
}
1312

14-
#' @export
1513
get_task <- function(examples) {
1614
attr(examples, "task")
1715
}

man/create_vocabulary.Rd

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

man/get_vocabulary.Rd

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

man/prepare_examples_dt.Rd

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

man/stack_layers.Rd

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

man/tokenize.Rd

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

0 commit comments

Comments
 (0)