Skip to content

Commit

Permalink
Add check for strange case where empty string is created for run number
Browse files Browse the repository at this point in the history
  • Loading branch information
gareth-j committed Oct 31, 2023
1 parent c97dabd commit 729f6cb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion R/shiny_priors.R
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ model_builder_shiny <- function(spatial_data,
4,
shiny::selectInput(inputId = "map_plot_type", label = "Plot type", choices = c("Predicted mean fields", "Random effect fields"), selected = "Predicted mean fields"),
shiny::selectInput(inputId = "map_data_type", label = "Data type", choices = c("Poisson", "Gaussian"), selected = data_distribution),
shiny::selectInput(inputId = "select_run_map", label = "Select run:", choices = c()),
),
shiny::column(
4,
Expand Down Expand Up @@ -469,7 +470,7 @@ model_builder_shiny <- function(spatial_data,
})

prediction_field <- shiny::reactive({
if (length(model_vals$parsed_outputs) == 0 || is.null(input$select_run_map)) {
if (length(model_vals$parsed_outputs) == 0 || input$select_run_map == "") {
return()
}

Expand Down

0 comments on commit 729f6cb

Please sign in to comment.