add proper caching for cost normalization graph

This commit is contained in:
2025-12-26 21:41:52 -05:00
parent a9afc1d548
commit bdb51cf064
+11 -3
View File
@@ -128,7 +128,7 @@ fluidRow(
column(
6,
div(
selectInput("stormBasin", "Basin", choices = "AL", width = "100%"),
#selectInput("stormBasin", "Basin", choices = "AL", width = "100%"),
selectInput(
"stormYear",
"Year",
@@ -174,7 +174,7 @@ observeEvent(input$stormYear, {
})
observeEvent(input$selectStorm, {
storm_selection$storm_basin <- input$stormBasin
storm_selection$storm_basin <- "AL"
storm_selection$storm_year <- input$stormYear
storm_selection$storm_name <- input$stormName
#storm_selection$is_selected <- TRUE
@@ -636,7 +636,15 @@ output$cost_index_chart <- renderDygraph({
dyLegend(show = "always", width = 400, hideOnMouseOut = FALSE) %>%
dyRangeSelector()
}) %>%
bindCache(storm_selection$storm_year, storm_selection$storm_name, storm_selection$storm_basin)
bindCache(
storm_selection$storm_year,
storm_selection$storm_name,
storm_selection$storm_basin,
input$storm_overview_cost_index_lf_select,
input$storm_overview_cost_index_mmh_mmp,
input$storm_overview_cost_index_scale,
input$storm_overview_cost_index_y_scale
)
hurdat_landfalls <- reactive({
req(storm_selection$storm_basin, storm_selection$storm_year, storm_selection$storm_name)