|
7 | 7 | #' This function allows to query data sets, tasks, flows, setups, runs, and evaluation measures |
8 | 8 | #' from \url{https://www.openml.org/search?type=data&sort=runs&status=active} using some simple filter criteria. |
9 | 9 | #' |
| 10 | +#' To find datasets for a specific task type, use [`list_oml_tasks()`] which supports filtering according to the task |
| 11 | +#' type. |
| 12 | +#' |
10 | 13 | #' @details |
11 | 14 | #' Filter values are usually provided as single atomic values (typically integer or character). |
12 | 15 | #' Provide a numeric vector of length 2 (`c(l, u)`) to find matches in the range \eqn{[l, u]}. |
|
44 | 47 | #' |
45 | 48 | #' @export |
46 | 49 | #' @examples |
47 | | -#' \donttest{ |
48 | | -#' ### query data sets |
49 | | -#' # search for titanic data set |
50 | | -#' data_sets = list_oml_data(data_name = "titanic") |
51 | | -#' print(data_sets) |
| 50 | +#' try({ |
| 51 | +#' ### query data sets |
| 52 | +#' # search for titanic data set |
| 53 | +#' data_sets = list_oml_data(data_name = "titanic") |
| 54 | +#' print(data_sets) |
52 | 55 | #' |
53 | | -#' # search for a reduced version |
54 | | -#' data_sets = list_oml_data( |
55 | | -#' data_name = "titanic", |
56 | | -#' number_instances = c(2200, 2300), |
57 | | -#' number_features = 4 |
58 | | -#' ) |
59 | | -#' print(data_sets) |
| 56 | +#' # search for a reduced version |
| 57 | +#' data_sets = list_oml_data( |
| 58 | +#' data_name = "titanic", |
| 59 | +#' number_instances = c(2200, 2300), |
| 60 | +#' number_features = 4 |
| 61 | +#' ) |
| 62 | +#' print(data_sets) |
60 | 63 | #' |
61 | | -#' ### search tasks for this data set |
62 | | -#' tasks = list_oml_tasks(data_id = data_sets$data_id) |
63 | | -#' print(tasks) |
| 64 | +#' ### search tasks for this data set |
| 65 | +#' tasks = list_oml_tasks(data_id = data_sets$data_id) |
| 66 | +#' print(tasks) |
64 | 67 | #' |
65 | 68 | #' |
66 | | -#' # query runs, group by number of runs per task_id |
67 | | -#' runs = list_oml_runs(task_id = tasks$task_id) |
68 | | -#' runs[, .N, by = task_id] |
69 | | -#' } |
| 69 | +#' # query runs, group by number of runs per task_id |
| 70 | +#' runs = list_oml_runs(task_id = tasks$task_id) |
| 71 | +#' runs[, .N, by = task_id] |
| 72 | +#' }, silent = TRUE) |
70 | 73 | list_oml_data = function(data_id = NULL, data_name = NULL, number_instances = NULL, number_features = NULL, |
71 | 74 | number_classes = NULL, number_missing_values = NULL, tag = NULL, limit = limit_default(), |
72 | 75 | test_server = test_server_default(), ...) { |
|
0 commit comments