Skip to content

Commit

Permalink
Add NAV_lce scenario.
Browse files Browse the repository at this point in the history
  • Loading branch information
robinhasse committed Jan 17, 2023
1 parent 6d5b00a commit dda0dc2
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion R/calcFEdemand.R
Original file line number Diff line number Diff line change
Expand Up @@ -1975,7 +1975,7 @@ calcFEdemand <- function(subtype = "FE") {
mselect(reminditems, scenario = navigateScenarios, item = nonIndustryItems),
addDim(mselect(reminditems, scenario = "gdp_SSP2EU", item = industryItems,
collapseNames = TRUE),
paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "all")),
paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "lce", "all")),
"scenario", 3.1)
)
}
Expand Down
8 changes: 4 additions & 4 deletions R/convertEDGE.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ convertEDGE <- function(x, subtype = "FE_stationary") {
addSSPnames <- function(x) {
do.call("mbind", lapply(c(paste0("SSP", c(1:5, "2EU", "2_lowEn")),
paste0("SDP", c("", "_EI", "_RC", "_MC")),
paste0("SSP2EU_NAV_", c("act", "tec", "ele", "all"))),
paste0("SSP2EU_NAV_", c("act", "tec", "ele", "lce", "all"))),
function(s) setNames(x, paste(s, getNames(x), sep = "."))
))
}
Expand Down Expand Up @@ -89,7 +89,7 @@ convertEDGE <- function(x, subtype = "FE_stationary") {
# duplicate SSP2 for SSP2_lowEn an SSP2EU for Navigate scenarios
wg <- mbind(
wg,
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "all")),
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "lce", "all")),
function(navScen) {
setItems(wg[,, "gdp_SSP2EU"], 3, navScen)
})),
Expand Down Expand Up @@ -319,7 +319,7 @@ convertEDGE <- function(x, subtype = "FE_stationary") {
# duplicate SSP2 for SSP2_lowEn an SSP2EU for Navigate scenarios
wg <- mbind(
wg,
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "all")),
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "lce", "all")),
function(navScen) {
setItems(wg[,, "gdp_SSP2EU"], 3, navScen)
})),
Expand All @@ -344,7 +344,7 @@ convertEDGE <- function(x, subtype = "FE_stationary") {
# duplicate SSP2 for SSP2_lowEn an SSP2EU for Navigate scenarios
wp <- mbind(
wp,
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "all")),
do.call("mbind", lapply(paste0("gdp_SSP2EU_NAV_", c("act", "tec", "ele", "lce", "all")),
function(navScen) {
setItems(wp[,, "gdp_SSP2EU"], 3, navScen)
})),
Expand Down
3 changes: 2 additions & 1 deletion R/readEDGE.R
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ readEDGE <- function(subtype = c("FE_stationary", "FE_buildings", "Capital", "Ca
# duplicate: SSP2 -> SSP2EU, SSP2_lowEn and SSP1 -> SDPs
mstationarySPP2s <- addDim(
mselect(mstationary, scenario = "SSP2", collapseNames = TRUE),
c("SSP2EU", "SSP2_lowEn", "SSP2EU_NAV_act", "SSP2EU_NAV_tec", "SSP2EU_NAV_ele", "SSP2EU_NAV_all"),
c("SSP2EU", "SSP2_lowEn", "SSP2EU_NAV_act", "SSP2EU_NAV_tec",
"SSP2EU_NAV_ele", "SSP2EU_NAV_lce", "SSP2EU_NAV_all"),
"scenario", 3.1)
mstationarySDPs <- addDim(
mselect(mstationary, scenario = "SSP1", collapseNames = TRUE),
Expand Down

0 comments on commit dda0dc2

Please sign in to comment.