mirror of
https://github.com/agdamsbo/FreesearchR.git
synced 2026-06-19 04:27:30 +02:00
translations
This commit is contained in:
parent
5326bb7cb7
commit
f957923514
6 changed files with 94 additions and 39 deletions
|
|
@ -15,9 +15,11 @@ data_visuals_ui <- function(id, tab_title = "Plots", ...) {
|
|||
bslib::layout_sidebar(
|
||||
sidebar = bslib::sidebar(
|
||||
bslib::accordion(
|
||||
id = "acc_plot",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
title = "Creating plot",
|
||||
value = "acc_pan_plot",
|
||||
title = "Create plot",
|
||||
icon = bsicons::bs_icon("graph-up"),
|
||||
shiny::uiOutput(outputId = ns("primary")),
|
||||
shiny::helpText(i18n$t('Only non-text variables are available for plotting. Go the "Data" to reclass data to plot.')),
|
||||
|
|
@ -36,6 +38,7 @@ data_visuals_ui <- function(id, tab_title = "Plots", ...) {
|
|||
shiny::helpText(i18n$t('Adjust settings, then press "Plot".'))
|
||||
),
|
||||
bslib::accordion_panel(
|
||||
value = "acc_pan_download",
|
||||
title = "Download",
|
||||
icon = bsicons::bs_icon("download"),
|
||||
shinyWidgets::noUiSliderInput(
|
||||
|
|
@ -125,6 +128,11 @@ data_visuals_server <- function(id,
|
|||
code = NULL
|
||||
)
|
||||
|
||||
shiny::observe({
|
||||
bslib::accordion_panel_update(id = "acc_plot", target = "acc_pan_plot",title = i18n$t("Create plot"))
|
||||
bslib::accordion_panel_update(id = "acc_plot", target = "acc_pan_download",title = i18n$t("Download"))
|
||||
})
|
||||
|
||||
# ## --- New attempt
|
||||
#
|
||||
# rv$plot.params <- shiny::reactive({
|
||||
|
|
@ -407,7 +415,7 @@ data_visuals_server <- function(id,
|
|||
plot <- rv$plot[[1]]
|
||||
}
|
||||
# browser()
|
||||
shiny::withProgress(message = i18n$t("Drawing the plot. Hold on for a moment.."), {
|
||||
shiny::withProgress(message = i18n$t("Drawing the plot. Hold tight for a moment.."), {
|
||||
ggplot2::ggsave(
|
||||
filename = file,
|
||||
plot = plot,
|
||||
|
|
|
|||
|
|
@ -60,12 +60,12 @@ data_missings_server <- function(id,
|
|||
|
||||
if (is.null(variabler()) || variabler() == "" || !variabler() %in% names(datar())) {
|
||||
if (anyNA(datar())){
|
||||
title <- "No variable chosen for analysis"
|
||||
title <- i18n$t("No variable chosen for analysis")
|
||||
} else {
|
||||
title <- "No missing observations"
|
||||
title <- i18n$t("No missing observations")
|
||||
}
|
||||
} else {
|
||||
title <- glue::glue("Missing vs non-missing observations in the variable **'{variabler()}'**")
|
||||
title <- glue::glue(i18n$t("Missing vs non-missing observations in the variable **'{variabler()}'**"))
|
||||
}
|
||||
|
||||
out <- rv$data() |>
|
||||
|
|
|
|||
|
|
@ -51,10 +51,11 @@ regression_ui <- function(id, ...) {
|
|||
sidebar = bslib::sidebar(
|
||||
shiny::uiOutput(outputId = ns("data_info"), inline = TRUE),
|
||||
bslib::accordion(
|
||||
id = "acc_reg",
|
||||
open = "acc_reg",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
value = "acc_reg",
|
||||
value = "acc_pan_reg",
|
||||
title = "Regression",
|
||||
icon = bsicons::bs_icon("calculator"),
|
||||
shiny::uiOutput(outputId = ns("outcome_var")),
|
||||
|
|
@ -133,14 +134,15 @@ regression_ui <- function(id, ...) {
|
|||
bslib::layout_sidebar(
|
||||
sidebar = bslib::sidebar(
|
||||
bslib::accordion(
|
||||
open = "acc_reg",
|
||||
id = "acc_coef_plot",
|
||||
open = "acc_pan_coef_plot",
|
||||
multiple = FALSE,
|
||||
do.call(
|
||||
bslib::accordion_panel,
|
||||
c(
|
||||
list(
|
||||
value = "acc_plot",
|
||||
title = "Coefficient plot",
|
||||
value = "acc_pan_coef_plot",
|
||||
title = "Coefficients plot",
|
||||
icon = bsicons::bs_icon("bar-chart-steps"),
|
||||
shiny::tags$br(),
|
||||
shiny::uiOutput(outputId = ns("plot_model"))
|
||||
|
|
@ -199,10 +201,11 @@ regression_ui <- function(id, ...) {
|
|||
bslib::layout_sidebar(
|
||||
sidebar = bslib::sidebar(
|
||||
bslib::accordion(
|
||||
open = "acc_reg",
|
||||
id = "acc_checks",
|
||||
open = "acc_pan_checks",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
value = "acc_checks",
|
||||
value = "acc_pan_checks",
|
||||
title = "Checks",
|
||||
icon = bsicons::bs_icon("clipboard-check"),
|
||||
shiny::uiOutput(outputId = ns("plot_checks"))
|
||||
|
|
@ -239,6 +242,12 @@ regression_server <- function(id,
|
|||
}
|
||||
})
|
||||
|
||||
shiny::observe({
|
||||
bslib::accordion_panel_update(id = "acc_reg", target = "acc_pan_reg", title = i18n$t("Regression"))
|
||||
bslib::accordion_panel_update(id = "acc_coef_plot", target = "acc_pan_coef_plot", title = i18n$t("Coefficients plot"))
|
||||
bslib::accordion_panel_update(id = "acc_checks", target = "acc_pan_checks", title = i18n$t("Checks"))
|
||||
})
|
||||
|
||||
output$data_info <- shiny::renderUI({
|
||||
shiny::req(regression_vars())
|
||||
shiny::req(data_r())
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ ui_elements <- function(selection) {
|
|||
shiny::column(width = 2),
|
||||
shiny::column(
|
||||
width = 8,
|
||||
shiny::uiOutput(outputId = "language_select"),
|
||||
# shiny::uiOutput(outputId = "language_select"),
|
||||
htmlOutput("intro_text")
|
||||
# shiny::includeHTML(i18n$t("www/intro.html"))
|
||||
# shiny::markdown(readLines(i18n$t("www/intro.md")))
|
||||
|
|
@ -180,7 +180,7 @@ ui_elements <- function(selection) {
|
|||
width = 9,
|
||||
shiny::uiOutput(outputId = "data_info", inline = TRUE),
|
||||
shiny::tags$p(
|
||||
i18n$t("Below you find a summary table for quick insigths, and on the right you can visualise data classes, browse data and apply different data filters.")
|
||||
i18n$t("Below you find a summary table for quick insigths, and on the right you can visualise data classes, browse observations and apply different data filters.")
|
||||
)
|
||||
),
|
||||
shiny::column(
|
||||
|
|
@ -195,7 +195,7 @@ ui_elements <- function(selection) {
|
|||
shiny::br(),
|
||||
shiny::actionButton(
|
||||
inputId = "modal_browse",
|
||||
label = i18n$t("Browse data"),
|
||||
label = i18n$t("Browse observations"),
|
||||
width = "100%",
|
||||
disabled = TRUE
|
||||
),
|
||||
|
|
@ -350,11 +350,12 @@ ui_elements <- function(selection) {
|
|||
sidebar = bslib::sidebar(
|
||||
shiny::uiOutput(outputId = "data_info_nochar", inline = TRUE),
|
||||
bslib::accordion(
|
||||
id="acc_chars",
|
||||
open = "acc_chars",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
open = TRUE,
|
||||
value = "acc_chars",
|
||||
value = "acc_pan_chars",
|
||||
title = "Settings",
|
||||
icon = bsicons::bs_icon("table"),
|
||||
shiny::uiOutput("strat_var"),
|
||||
|
|
@ -395,11 +396,12 @@ ui_elements <- function(selection) {
|
|||
sidebar = bslib::sidebar(
|
||||
# shiny::uiOutput(outputId = "data_info_nochar", inline = TRUE),
|
||||
bslib::accordion(
|
||||
id="acc_cor",
|
||||
open = "acc_chars",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
value = "acc_cor",
|
||||
title = "Correlations",
|
||||
value = "acc_pan_cor",
|
||||
title = "Settings",
|
||||
icon = bsicons::bs_icon("bounding-box"),
|
||||
shiny::uiOutput("outcome_var_cor"),
|
||||
shiny::helpText("To avoid evaluating the correlation of the outcome variable, this can be excluded from the plot or select 'none'."),
|
||||
|
|
@ -427,17 +429,19 @@ ui_elements <- function(selection) {
|
|||
bslib::layout_sidebar(
|
||||
sidebar = bslib::sidebar(
|
||||
bslib::accordion(
|
||||
id = "acc_mis",
|
||||
open = "acc_chars",
|
||||
multiple = FALSE,
|
||||
bslib::accordion_panel(
|
||||
vlaue = "acc_mis",
|
||||
title = "Missings",
|
||||
value = "acc_pan_mis",
|
||||
title = "Settings",
|
||||
icon = bsicons::bs_icon("x-circle"),
|
||||
shiny::uiOutput("missings_var"),
|
||||
shiny::helpText("To consider if data is missing by random, choose the outcome/dependent variable, if it has any missings to evaluate if there is a significant difference across other variables depending on missing data or not.")
|
||||
)
|
||||
)
|
||||
),
|
||||
validation_ui("validation_mcar"),
|
||||
data_missings_ui(id = "missingness")
|
||||
)
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue