Skip to content

Commit

Permalink
Update utils.R
Browse files Browse the repository at this point in the history
Changed rule in interpolating GCM scenarios from 2 to 1
Changed rule when interpolating scalars from 1:2 to 2:2
  • Loading branch information
knoiva-indecon committed Aug 7, 2024
1 parent c41bf5e commit acd54b6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ format_gcamData_byScenario <- function(

### Interpolate temperatures by year
df0 <- df0 |> mutate(region = "NationalTotal")
df0 <- df0 |> interpolate_annual(years=years0, column="temp_C_global", rule=2:2)
df0 <- df0 |> interpolate_annual(years=years0, column="temp_C_global", rule=1)
df0 <- df0 |> select(-c("region"))
# df0_i |> glimpse()

Expand Down Expand Up @@ -472,10 +472,9 @@ fun_formatScalars <- function(
data_i <- data_i |> interpolate_annual(
years = years_x,
column = "value",
rule = 1:2,
rule = 2:2,
method = method_i,
byState = TRUE
# byState = byState_i
) ### End interpolate_annual
### Return
return(data_i)
Expand Down

0 comments on commit acd54b6

Please sign in to comment.