Skip to content

Commit

Permalink
Fix the name for scenario selection
Browse files Browse the repository at this point in the history
  • Loading branch information
mengqi-z committed Feb 19, 2024
1 parent 1b3b0a6 commit 9cfc798
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion R/diagnostics.R
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ diagnostics <- function(hdcd_segment = tibble::tibble(),
noaa_name <- paste('NOAA', noaa_year_i, sep = '-')

} else {
scenario_sel <- paste('ncdf_', year_i)
scenario_sel <- paste0('ncdf_', year_i)
}

# filter year and format for plotting
Expand Down
12 changes: 12 additions & 0 deletions inst/extras/dev_tests.R
Original file line number Diff line number Diff line change
Expand Up @@ -228,3 +228,15 @@ helios::diagnostics(
folder = file.path(getwd(), 'output'),
name_append = 'combined_hdhcdh_monthly_us49'
)

# Test diagnostics with NERSC output on monthly HDHCDH at Gridregion
hdhcdh_gridregion <- data.table::fread(
'C:/WorkSpace/IM3/helios/hddcdd/nersc/combined_outputs_hdcd_rcp45cooler_ssp3/combined_hdhcdh_2020_2099_monthly_gridregion.csv'
)

helios::diagnostics(
hdcd_monthly = hdhcdh_gridregion,
min_diagnostic_months = 6,
folder = file.path(getwd(), 'output'),
name_append = 'combined_hdhcdh_monthly_gridregion'
)

0 comments on commit 9cfc798

Please sign in to comment.