Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Signed-off-by: Marcin <[email protected]>
  • Loading branch information
m7pr authored Nov 14, 2024
1 parent 56872ec commit e86e19f
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions vignettes/decorate-multiple-modules-outputs.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ tm_decorated_plot <- function(
})
observeEvent(input$dataname, {
req(input$dataname)
updateSelectInput(inputId = "x", choices = colnames(data()[[input$dataname]]))
updateSelectInput(inputId = "y", label = "select y", choices = colnames(data()[[input$dataname]]))
})
Expand All @@ -72,8 +73,7 @@ tm_decorated_plot <- function(
q1_1 <- reactive({
req(input$dataname, input$x, input$y)
data() |>
within(
within(data(),
{

Check warning on line 77 in vignettes/decorate-multiple-modules-outputs.Rmd

View workflow job for this annotation

GitHub Actions / SuperLinter 🦸‍♀️ / Lint R code 🧶

file=vignettes/decorate-multiple-modules-outputs.Rmd,line=77,col=14,[indentation_linter] Indentation should be 12 spaces but is 14 spaces.
plot_1 <- ggplot2::ggplot(dataname, ggplot2::aes(x = x, y = y)) +
ggplot2::geom_point() +
Expand All @@ -87,8 +87,7 @@ tm_decorated_plot <- function(
q2_1 <- reactive({
req(input$dataname, input$x, input$y)
data() |>
within(
within(data(),
{

Check warning on line 91 in vignettes/decorate-multiple-modules-outputs.Rmd

View workflow job for this annotation

GitHub Actions / SuperLinter 🦸‍♀️ / Lint R code 🧶

file=vignettes/decorate-multiple-modules-outputs.Rmd,line=91,col=14,[indentation_linter] Indentation should be 12 spaces but is 14 spaces.
plot_2 <- ggplot2::ggplot(dataname, ggplot2::aes(x = x, y = y)) +
ggplot2::geom_point() +
Expand All @@ -100,8 +99,8 @@ tm_decorated_plot <- function(
)
})
q1_2 <- srv_teal_data("decorate_1", data = q1_1, data_module = decorator_objs[[1]], modules = module())
q2_2 <- srv_teal_data("decorate_2", data = q2_1, data_module = decorator_objs[[2]], modules = module())
q1_2 <- srv_transform_data("decorate_1", data = q1_1, data_module = decorator_objs[[1]], modules = module())
q2_2 <- srv_transform_data("decorate_2", data = q2_1, data_module = decorator_objs[[2]], modules = module())
plot_r <- reactive({
Expand Down Expand Up @@ -144,7 +143,7 @@ interactive_decorator_1 <- teal_transform_module(
moduleServer(id, function(input, output, session) {
reactive({
req(data())
data() |> within(
within(data(),
{
plot_1 <- plot_1 +
xlab(x_axis_title)
Expand All @@ -167,7 +166,7 @@ interactive_decorator_2 <- teal_transform_module(
moduleServer(id, function(input, output, session) {
reactive({
req(data())
data() |> within(
within(data(),
{
plot_2 <- plot_2 +
xlab(x_axis_title)
Expand Down

0 comments on commit e86e19f

Please sign in to comment.