From e8cf59435363a185f17eaacb3bcf8bbc00d57c5b Mon Sep 17 00:00:00 2001 From: GeraldineGomez Date: Wed, 18 Sep 2024 11:57:00 -0500 Subject: [PATCH] fix: lintr space and lines --- R/cleaning_data.R | 6 ++++-- R/utils.R | 2 +- inst/rmarkdown/templates/reports/skeleton/skeleton.Rmd | 4 ++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/R/cleaning_data.R b/R/cleaning_data.R index 5d5801bc..f2515bff 100644 --- a/R/cleaning_data.R +++ b/R/cleaning_data.R @@ -148,8 +148,10 @@ convert_edad <- function(data_event, dplyr::mutate( data_event, {{ col_edad }} := dplyr::case_when( - .data[[col_uni_med]] == 1 ~ round(.data[[col_edad]] * 365 * 24 * 60, 3), - .data[[col_uni_med]] == 2 ~ round(.data[[col_edad]] * 30 * 24 * 60, 3), + .data[[col_uni_med]] == 1 ~ + round(.data[[col_edad]] * 365 * 24 * 60, 3), + .data[[col_uni_med]] == 2 ~ + round(.data[[col_edad]] * 30 * 24 * 60, 3), .data[[col_uni_med]] == 3 ~ round(.data[[col_edad]] * 24 * 60, 3), .data[[col_uni_med]] == 4 ~ round(.data[[col_edad]] * 60, 3), .data[[col_uni_med]] == 5 ~ round(.data[[col_edad]], 3) diff --git a/R/utils.R b/R/utils.R index 5d711f60..2c482f78 100644 --- a/R/utils.R +++ b/R/utils.R @@ -433,7 +433,7 @@ obtener_eventos_relacionados <- function(nombre_event, years) { grupo_events <- list_events[which(stringr::str_detect( list_events$enfermedad, - gsub("([()])", "\\\\\\1",substr( + gsub("([()])", "\\\\\\1", substr( nombre_event, 1, nchar(nombre_event) - 1 diff --git a/inst/rmarkdown/templates/reports/skeleton/skeleton.Rmd b/inst/rmarkdown/templates/reports/skeleton/skeleton.Rmd index 2d87869b..450649b8 100644 --- a/inst/rmarkdown/templates/reports/skeleton/skeleton.Rmd +++ b/inst/rmarkdown/templates/reports/skeleton/skeleton.Rmd @@ -1,11 +1,11 @@ --- output: - pdf_document: - number_sections: true html_document: number_sections: true fig_caption: true css: style.css + pdf_document: + number_sections: true word_document: number_sections: true header-includes: