From ce4ceee816a58fab0eeeb9fce6005cfae76f83f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Fri, 8 Nov 2024 10:52:56 +0100 Subject: [PATCH 1/7] Remove TealData and connectors --- NAMESPACE | 51 -------- R/deprecated.R | 326 ------------------------------------------------ R/teal_data.R | 30 ++--- man/TealData.Rd | 176 -------------------------- 4 files changed, 7 insertions(+), 576 deletions(-) delete mode 100644 man/TealData.Rd diff --git a/NAMESPACE b/NAMESPACE index 71db8957b..04fb85742 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -19,70 +19,19 @@ S3method(parents,teal_data) S3method(print,join_keys) export("col_labels<-") export("datanames<-") -export("get_join_keys<-") export("join_keys<-") export("parents<-") -export(as_cdisc) -export(callable_code) -export(callable_function) export(cdisc_data) -export(cdisc_data_connector) -export(cdisc_data_file) -export(cdisc_dataset) -export(cdisc_dataset_connector) -export(cdisc_dataset_connector_file) -export(cdisc_dataset_file) -export(code_cdisc_dataset_connector) -export(code_dataset_connector) export(col_labels) export(col_relabel) -export(csv_cdisc_dataset_connector) -export(csv_dataset_connector) -export(data_connection) export(datanames) -export(dataset) -export(dataset_connector) -export(dataset_connector_file) -export(dataset_file) export(example_cdisc_data) -export(fun_cdisc_dataset_connector) -export(fun_dataset_connector) -export(get_attrs) -export(get_cdisc_keys) -export(get_dataname) -export(get_dataset) -export(get_dataset_label) -export(get_datasets) -export(get_join_keys) -export(get_key_duplicates) -export(get_keys) export(get_labels) -export(get_raw_data) -export(is_pulled) export(join_key) export(join_keys) -export(load_dataset) -export(load_datasets) -export(mae_dataset) -export(mutate_data) -export(mutate_dataset) export(parent) export(parents) -export(python_cdisc_dataset_connector) -export(python_code) -export(python_dataset_connector) -export(rds_cdisc_dataset_connector) -export(rds_dataset_connector) -export(read_script) -export(relational_data_connector) -export(script_cdisc_dataset_connector) -export(script_dataset_connector) -export(set_args) -export(set_keys) export(teal_data) -export(teal_data_file) -export(to_relational_data) -export(validate_metadata) export(verify) exportMethods(get_code) exportMethods(show) diff --git a/R/deprecated.R b/R/deprecated.R index d4b3e9e93..5d9d6d162 100644 --- a/R/deprecated.R +++ b/R/deprecated.R @@ -1,20 +1,3 @@ -#' Deprecated `TealData` class and related functions -#' -#' @description -#' `r lifecycle::badge("deprecated")` -#' -#' The `TealData` class and associated functions have been deprecated. Use [teal_data()] instead. -#' See the [Migration guide](https://github.com/insightsengineering/teal/discussions/945) for details. -#' -#' @name TealData -#' -#' @param ... any argument supported in `TealData` related functions. -#' -#' @return nothing -#' @seealso [cdisc_data()] , [join_keys()] -#' -NULL - .deprecate_function <- function(what, details) { lifecycle::deprecate_stop( when = "0.4.0", @@ -23,315 +6,6 @@ NULL ) } -deprecation_detail <- "Find more information on https://github.com/insightsengineering/teal/discussions/945" - -#' @rdname TealData -#' @export -as_cdisc <- function(...) { - .deprecate_function("as_cdisc()", deprecation_detail) -} - -#' @rdname TealData -#' @export -callable_code <- function(...) { - .deprecate_function("callable_code()", deprecation_detail) -} - -#' @rdname TealData -#' @export -callable_function <- function(...) { - .deprecate_function("callable_function()", deprecation_detail) -} - -#' @rdname TealData -#' @export -code_dataset_connector <- function(...) { - .deprecate_function("code_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -code_cdisc_dataset_connector <- function(...) { - .deprecate_function("code_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -csv_dataset_connector <- function(...) { - .deprecate_function("csv_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -csv_cdisc_dataset_connector <- function(...) { - .deprecate_function("csv_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -python_code <- function(...) { - .deprecate_function("python_code()", deprecation_detail) -} - -#' @rdname TealData -#' @export -python_dataset_connector <- function(...) { - .deprecate_function("python_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -python_cdisc_dataset_connector <- function(...) { - .deprecate_function("python_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_data_connector <- function(...) { - .deprecate_function("cdisc_data_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_dataset <- function(...) { - .deprecate_function("cdisc_dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_dataset_connector <- function(...) { - .deprecate_function("cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_dataset_connector_file <- function(...) { - .deprecate_function("cdisc_dataset_connector_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_dataset_file <- function(...) { - .deprecate_function("cdisc_dataset_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -dataset <- function(...) { - .deprecate_function("dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -dataset_connector <- function(...) { - .deprecate_function("dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -dataset_connector_file <- function(...) { - .deprecate_function("dataset_connector_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -dataset_file <- function(...) { - .deprecate_function("dataset_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -data_connection <- function(...) { - .deprecate_function("data_connection()", deprecation_detail) -} - -#' @rdname TealData -#' @export -fun_dataset_connector <- function(...) { - .deprecate_function("fun_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -fun_cdisc_dataset_connector <- function(...) { - .deprecate_function("fun_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -relational_data_connector <- function(...) { - .deprecate_function("relational_data_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -mae_dataset <- function(...) { - .deprecate_function("mae_dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_attrs <- function(...) { - .deprecate_function("get_attrs()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_dataset_label <- function(...) { - .deprecate_function("get_dataset_label()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_dataset <- function(...) { - .deprecate_function("get_dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_datasets <- function(...) { - .deprecate_function("get_datasets()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_dataname <- function(...) { - .deprecate_function("get_dataname()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_key_duplicates <- function(...) { - .deprecate_function("get_key_duplicates()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_keys <- function(...) { - .deprecate_function("get_keys()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_raw_data <- function(...) { - .deprecate_function("get_raw_data()", deprecation_detail) -} - -#' @rdname TealData -#' @export -is_pulled <- function(...) { - .deprecate_function("is_pulled()", deprecation_detail) -} - -#' @rdname TealData -#' @export -load_dataset <- function(...) { - .deprecate_function("load_dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -load_datasets <- function(...) { - .deprecate_function("load_datasets()", deprecation_detail) -} - -#' @rdname TealData -#' @export -mutate_data <- function(...) { - .deprecate_function("mutate_data()", deprecation_detail) -} - -#' @rdname TealData -#' @export -mutate_dataset <- function(...) { - .deprecate_function("mutate_dataset()", deprecation_detail) -} - -#' @rdname TealData -#' @export -set_args <- function(...) { - .deprecate_function("set_args()", deprecation_detail) -} - -#' @rdname TealData -#' @export -rds_dataset_connector <- function(...) { - .deprecate_function("rds_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -rds_cdisc_dataset_connector <- function(...) { - .deprecate_function("rds_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -script_dataset_connector <- function(...) { - .deprecate_function("script_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -script_cdisc_dataset_connector <- function(...) { - .deprecate_function("script_cdisc_dataset_connector()", deprecation_detail) -} - -#' @rdname TealData -#' @export -set_keys <- function(...) { - .deprecate_function("set_keys()", deprecation_detail) -} - -#' @rdname TealData -#' @export -read_script <- function(...) { - .deprecate_function("read_script()", deprecation_detail) -} - -#' @rdname TealData -#' @export -to_relational_data <- function(...) { - .deprecate_function("to_relational_data()", deprecation_detail) -} - -#' @rdname TealData -#' @export -validate_metadata <- function(...) { - .deprecate_function("validate_metadata()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_cdisc_keys <- function(...) { - .deprecate_function("get_cdisc_keys()", deprecation_detail) -} - -#' @rdname TealData -#' @export -cdisc_data_file <- function(...) { - .deprecate_function("cdisc_data_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -teal_data_file <- function(...) { - .deprecate_function("teal_data_file()", deprecation_detail) -} - -#' @rdname TealData -#' @export -get_join_keys <- function(...) { - .deprecate_function("get_join_keys()", "Use `join_keys(data)` instead.") -} - -#' @rdname TealData -#' @param value value to assign -#' @export -`get_join_keys<-` <- function(..., value) { - .deprecate_function("`get_join_keys<-`()", "Use `join_keys(x) <- ...`") -} - #' @rdname col_labels #' @include formatters_var_labels.R #' @details diff --git a/R/teal_data.R b/R/teal_data.R index ea32e624a..48e504a4f 100644 --- a/R/teal_data.R +++ b/R/teal_data.R @@ -42,28 +42,12 @@ teal_data <- function(..., ) } - if ( - checkmate::test_list( - data_objects, - types = c("TealDataConnector", "TealDataset", "TealDatasetConnector"), - min.len = 1 - ) - ) { - lifecycle::deprecate_stop( - when = "0.4.0", - "teal_data( - data_objects = 'should use data directly. Using TealDatasetConnector and TealDataset is deprecated. - Find more information on https://github.com/insightsengineering/teal/discussions/945' - )" - ) - } else { - if (length(data_objects) > 0 && !checkmate::test_names(names(data_objects), type = "named")) { - stop("Dot (`...`) arguments on `teal_data()` must be named.") - } - new_teal_data( - data = data_objects, - code = code, - join_keys = join_keys - ) + if (length(data_objects) > 0 && !checkmate::test_names(names(data_objects), type = "named")) { + stop("Dot (`...`) arguments on `teal_data()` must be named.") } + new_teal_data( + data = data_objects, + code = code, + join_keys = join_keys + ) } diff --git a/man/TealData.Rd b/man/TealData.Rd deleted file mode 100644 index cd9bf669d..000000000 --- a/man/TealData.Rd +++ /dev/null @@ -1,176 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/deprecated.R -\name{TealData} -\alias{TealData} -\alias{as_cdisc} -\alias{callable_code} -\alias{callable_function} -\alias{code_dataset_connector} -\alias{code_cdisc_dataset_connector} -\alias{csv_dataset_connector} -\alias{csv_cdisc_dataset_connector} -\alias{python_code} -\alias{python_dataset_connector} -\alias{python_cdisc_dataset_connector} -\alias{cdisc_data_connector} -\alias{cdisc_dataset} -\alias{cdisc_dataset_connector} -\alias{cdisc_dataset_connector_file} -\alias{cdisc_dataset_file} -\alias{dataset} -\alias{dataset_connector} -\alias{dataset_connector_file} -\alias{dataset_file} -\alias{data_connection} -\alias{fun_dataset_connector} -\alias{fun_cdisc_dataset_connector} -\alias{relational_data_connector} -\alias{mae_dataset} -\alias{get_attrs} -\alias{get_dataset_label} -\alias{get_dataset} -\alias{get_datasets} -\alias{get_dataname} -\alias{get_key_duplicates} -\alias{get_keys} -\alias{get_raw_data} -\alias{is_pulled} -\alias{load_dataset} -\alias{load_datasets} -\alias{mutate_data} -\alias{mutate_dataset} -\alias{set_args} -\alias{rds_dataset_connector} -\alias{rds_cdisc_dataset_connector} -\alias{script_dataset_connector} -\alias{script_cdisc_dataset_connector} -\alias{set_keys} -\alias{read_script} -\alias{to_relational_data} -\alias{validate_metadata} -\alias{get_cdisc_keys} -\alias{cdisc_data_file} -\alias{teal_data_file} -\alias{get_join_keys} -\alias{get_join_keys<-} -\title{Deprecated \code{TealData} class and related functions} -\usage{ -as_cdisc(...) - -callable_code(...) - -callable_function(...) - -code_dataset_connector(...) - -code_cdisc_dataset_connector(...) - -csv_dataset_connector(...) - -csv_cdisc_dataset_connector(...) - -python_code(...) - -python_dataset_connector(...) - -python_cdisc_dataset_connector(...) - -cdisc_data_connector(...) - -cdisc_dataset(...) - -cdisc_dataset_connector(...) - -cdisc_dataset_connector_file(...) - -cdisc_dataset_file(...) - -dataset(...) - -dataset_connector(...) - -dataset_connector_file(...) - -dataset_file(...) - -data_connection(...) - -fun_dataset_connector(...) - -fun_cdisc_dataset_connector(...) - -relational_data_connector(...) - -mae_dataset(...) - -get_attrs(...) - -get_dataset_label(...) - -get_dataset(...) - -get_datasets(...) - -get_dataname(...) - -get_key_duplicates(...) - -get_keys(...) - -get_raw_data(...) - -is_pulled(...) - -load_dataset(...) - -load_datasets(...) - -mutate_data(...) - -mutate_dataset(...) - -set_args(...) - -rds_dataset_connector(...) - -rds_cdisc_dataset_connector(...) - -script_dataset_connector(...) - -script_cdisc_dataset_connector(...) - -set_keys(...) - -read_script(...) - -to_relational_data(...) - -validate_metadata(...) - -get_cdisc_keys(...) - -cdisc_data_file(...) - -teal_data_file(...) - -get_join_keys(...) - -get_join_keys(...) <- value -} -\arguments{ -\item{...}{any argument supported in \code{TealData} related functions.} - -\item{value}{value to assign} -} -\value{ -nothing -} -\description{ -\ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} - -The \code{TealData} class and associated functions have been deprecated. Use \code{\link[=teal_data]{teal_data()}} instead. -See the \href{https://github.com/insightsengineering/teal/discussions/945}{Migration guide} for details. -} -\seealso{ -\code{\link[=cdisc_data]{cdisc_data()}} , \code{\link[=join_keys]{join_keys()}} -} From 0bdfa588e014ac6d91834b66510aa7b67e0c1ea4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Fri, 8 Nov 2024 11:00:19 +0100 Subject: [PATCH 2/7] Remove check argument from teal_data --- R/cdisc_data.R | 5 ++--- R/teal_data.R | 15 ++------------- man/cdisc_data.Rd | 6 ++---- man/teal_data.Rd | 5 ++--- 4 files changed, 8 insertions(+), 23 deletions(-) diff --git a/R/cdisc_data.R b/R/cdisc_data.R index ffbb51ed8..8faa833f4 100644 --- a/R/cdisc_data.R +++ b/R/cdisc_data.R @@ -32,7 +32,6 @@ #' cdisc_data <- function(..., join_keys = teal.data::default_cdisc_join_keys[names(rlang::list2(...))], - code = character(0), - check) { - teal_data(..., join_keys = join_keys, code = code, check = check) + code = character(0)) { + teal_data(..., join_keys = join_keys, code = code) } diff --git a/R/teal_data.R b/R/teal_data.R index 48e504a4f..dd7dfbe18 100644 --- a/R/teal_data.R +++ b/R/teal_data.R @@ -14,8 +14,7 @@ #' @param code (`character`, `language`) optional code to reproduce the datasets provided in `...`. #' Note this code is not executed and the `teal_data` may not be reproducible #' -#' @param check (`logical`) `r lifecycle::badge("deprecated")` -#' Use [verify()] to verify code reproducibility . +#' Use [verify()] to verify code reproducibility . #' #' @return A `teal_data` object. #' @@ -26,21 +25,11 @@ #' teal_data <- function(..., join_keys = teal.data::join_keys(), - code = character(0), - check) { + code = character(0)) { data_objects <- rlang::list2(...) if (inherits(join_keys, "join_key_set")) { join_keys <- teal.data::join_keys(join_keys) } - if (!missing(check)) { - lifecycle::deprecate_stop( - when = "0.4.0", - "teal_data( - check = 'check argument is deprecated. Use `verify()` to verify code reproducibility. - Find more information on https://github.com/insightsengineering/teal/discussions/945' - )" - ) - } if (length(data_objects) > 0 && !checkmate::test_names(names(data_objects), type = "named")) { stop("Dot (`...`) arguments on `teal_data()` must be named.") diff --git a/man/cdisc_data.Rd b/man/cdisc_data.Rd index 05f8ee3fe..fe9f80de8 100644 --- a/man/cdisc_data.Rd +++ b/man/cdisc_data.Rd @@ -7,8 +7,7 @@ cdisc_data( ..., join_keys = teal.data::default_cdisc_join_keys[names(rlang::list2(...))], - code = character(0), - check + code = character(0) ) } \arguments{ @@ -20,9 +19,8 @@ If empty then it would be automatically derived basing on intersection of datase For ADAM datasets it would be automatically derived.} \item{code}{(\code{character}, \code{language}) optional code to reproduce the datasets provided in \code{...}. -Note this code is not executed and the \code{teal_data} may not be reproducible} +Note this code is not executed and the \code{teal_data} may not be reproducible -\item{check}{(\code{logical}) \ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} Use \code{\link[=verify]{verify()}} to verify code reproducibility .} } \value{ diff --git a/man/teal_data.Rd b/man/teal_data.Rd index b249aece4..02aebebe0 100644 --- a/man/teal_data.Rd +++ b/man/teal_data.Rd @@ -4,7 +4,7 @@ \alias{teal_data} \title{Comprehensive data integration function for \code{teal} applications} \usage{ -teal_data(..., join_keys = teal.data::join_keys(), code = character(0), check) +teal_data(..., join_keys = teal.data::join_keys(), code = character(0)) } \arguments{ \item{...}{any number of objects (presumably data objects) provided as \code{name = value} pairs.} @@ -14,9 +14,8 @@ optional object with datasets column names used for joining. If empty then no joins between pairs of objects.} \item{code}{(\code{character}, \code{language}) optional code to reproduce the datasets provided in \code{...}. -Note this code is not executed and the \code{teal_data} may not be reproducible} +Note this code is not executed and the \code{teal_data} may not be reproducible -\item{check}{(\code{logical}) \ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} Use \code{\link[=verify]{verify()}} to verify code reproducibility .} } \value{ From 5ae25adaf8c1698be30d68813466c3a352beb8ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Fri, 8 Nov 2024 11:41:31 +0100 Subject: [PATCH 3/7] Remove again code related to connectors and TealData --- R/teal_data.R | 32 ++++++++------------------------ 1 file changed, 8 insertions(+), 24 deletions(-) diff --git a/R/teal_data.R b/R/teal_data.R index 3e3557cbb..523f51c50 100644 --- a/R/teal_data.R +++ b/R/teal_data.R @@ -31,29 +31,13 @@ teal_data <- function(..., join_keys <- teal.data::join_keys(join_keys) } - if ( - checkmate::test_list( - data_objects, - types = c("TealDataConnector", "TealDataset", "TealDatasetConnector"), - min.len = 1 - ) - ) { - lifecycle::deprecate_stop( - when = "0.4.0", - "teal_data( - data_objects = 'should use data directly. Using TealDatasetConnector and TealDataset is deprecated. - Find more information on https://github.com/insightsengineering/teal/discussions/945' - )" - ) - } else { - if (length(data_objects) > 0 && !checkmate::test_names(names(data_objects), type = "named")) { - stop("Dot (`...`) arguments on `teal_data()` must be named.") - } - methods::new( - "teal_data", - .xData = data_objects, - code = code, - join_keys = join_keys - ) + if (length(data_objects) > 0 && !checkmate::test_names(names(data_objects), type = "named")) { + stop("Dot (`...`) arguments on `teal_data()` must be named.") } + methods::new( + "teal_data", + .xData = data_objects, + code = code, + join_keys = join_keys + ) } From b2d4fc2da40bdab873586d11fa125bdbb4d895ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Fri, 8 Nov 2024 12:06:43 +0100 Subject: [PATCH 4/7] Remove TealData from the website --- _pkgdown.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/_pkgdown.yml b/_pkgdown.yml index cc6bbb0c3..e77e1bf71 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -58,5 +58,4 @@ reference: - example_cdisc_data - title: Deprecated contents: - - TealData - get_labels From 865962ce83072ac42068c436e8251daa87d0a7d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Mon, 11 Nov 2024 12:17:39 +0100 Subject: [PATCH 5/7] Remove get_labels --- NAMESPACE | 1 - R/deprecated.R | 20 -------------------- _pkgdown.yml | 3 --- man/col_labels.Rd | 10 +--------- 4 files changed, 1 insertion(+), 33 deletions(-) diff --git a/NAMESPACE b/NAMESPACE index 843d6d2dc..92d44016a 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -30,7 +30,6 @@ export(col_labels) export(col_relabel) export(datanames) export(example_cdisc_data) -export(get_labels) export(join_key) export(join_keys) export(parent) diff --git a/R/deprecated.R b/R/deprecated.R index fd8501217..af7018525 100644 --- a/R/deprecated.R +++ b/R/deprecated.R @@ -1,23 +1,3 @@ -.deprecate_function <- function(what, details) { - lifecycle::deprecate_stop( - when = "0.4.0", - what = what, - details = details - ) -} - -#' @rdname col_labels -#' @include formatters_var_labels.R -#' @details -#' `r lifecycle::badge("deprecated")` -#' -#' In previous versions of `teal.data` labels were managed with `get_labels()`. -#' This function is deprecated as of `0.4.0`, use `col_labels` instead. -#' @export -get_labels <- function(...) { - .deprecate_function("get_labels()", "Use col_labels(data)") -} - #' Names of data sets in `teal_data` object #' #' @description diff --git a/_pkgdown.yml b/_pkgdown.yml index e77e1bf71..70c6032aa 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -56,6 +56,3 @@ reference: - col_labels<- - col_relabel - example_cdisc_data - - title: Deprecated - contents: - - get_labels diff --git a/man/col_labels.Rd b/man/col_labels.Rd index abea3d4bf..8d43c4242 100644 --- a/man/col_labels.Rd +++ b/man/col_labels.Rd @@ -1,10 +1,9 @@ % Generated by roxygen2: do not edit by hand -% Please edit documentation in R/formatters_var_labels.R, R/deprecated.R +% Please edit documentation in R/formatters_var_labels.R \name{col_labels} \alias{col_labels} \alias{col_labels<-} \alias{col_relabel} -\alias{get_labels} \title{Variable labels} \source{ These functions were taken from @@ -17,8 +16,6 @@ col_labels(x, fill = FALSE) col_labels(x) <- value col_relabel(x, ...) - -get_labels(...) } \arguments{ \item{x}{(\code{data.frame} or \code{DataFrame}) data object} @@ -45,11 +42,6 @@ Get or set variable labels in a \code{data.frame}. \details{ Variable labels can be stored as a \code{label} attribute set on individual variables. These functions get or set this attribute, either on all (\code{col_labels}) or some variables (\code{col_relabel}). - -\ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} - -In previous versions of \code{teal.data} labels were managed with \code{get_labels()}. -This function is deprecated as of \verb{0.4.0}, use \code{col_labels} instead. } \examples{ x <- iris From f523cc4293bed06333faa0cf549c761a92572ed3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= Date: Mon, 11 Nov 2024 12:17:58 +0100 Subject: [PATCH 6/7] Add NEWS entry --- NEWS.md | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS.md b/NEWS.md index 765092fb9..bd3ce86c2 100644 --- a/NEWS.md +++ b/NEWS.md @@ -5,6 +5,7 @@ - Soft deprecate `datanames` argument of `get_code()`. Use `names` instead. - Soft deprecate of `datanames()`. Use `names()` instead. - Deprecate of `datanames(x) <- value`. Does nothing, replace with renaming the objects inside the environment. +- All arguments and functions deprecated on 0.4.0 were removed. ### Enhancements From d7e342e948b0b7f7bc2f802580f5deeb43e8dc0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Revilla?= <185338939+llrs-roche@users.noreply.github.com> Date: Mon, 11 Nov 2024 14:14:24 +0100 Subject: [PATCH 7/7] Update NEWS.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Marcin <133694481+m7pr@users.noreply.github.com> Signed-off-by: LluĂ­s Revilla <185338939+llrs-roche@users.noreply.github.com> --- NEWS.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS.md b/NEWS.md index cc011a3c5..60b29a348 100644 --- a/NEWS.md +++ b/NEWS.md @@ -5,7 +5,7 @@ - Soft deprecate `datanames` argument of `get_code()`. Use `names` instead. - Soft deprecate of `datanames()`. Use `names()` instead. - Deprecate of `datanames(x) <- value`. Does nothing, replace with renaming the objects inside the environment. -- All arguments and functions deprecated on 0.4.0 were removed. +- All parameters and functions deprecated on 0.4.0 were removed. ### Enhancements