Skip to content

Commit

Permalink
remove adjustment of investment variables from reportLCOE
Browse files Browse the repository at this point in the history
  • Loading branch information
fbenke-pik committed Nov 5, 2024
1 parent ddc699c commit 939d7e7
Showing 1 changed file with 0 additions and 22 deletions.
22 changes: 0 additions & 22 deletions R/reportLCOE.R
Original file line number Diff line number Diff line change
Expand Up @@ -151,28 +151,6 @@ reportLCOE <- function(gdx, output.type = "both", gdx_ref = NULL) {
# capacity additions per year
vm_deltaCap <- readGDX(gdx, name = c("vm_deltaCap"), field = "l", format = "first_found")[, ttot, ]

# apply 'modifyInvestmentVariables' to shift from the model-internal time coverage (deltacap and investment
# variables for step t represent the average of the years from t-4years to t) to the general convention for
# the reporting template (all variables represent the average of the years from t-2.5years to t+2.5years)
if (!is.null(gdx_ref)) {
cm_startyear <- as.integer(readGDX(gdx, name = "cm_startyear", format = "simplest"))

vm_costInvTeDirRef <- readGDX(gdx_ref, name = c("vm_costInvTeDir", "v_costInvTeDir", "v_directteinv"),
field = "l", format = "first_found")[, ttot, ]
vm_costInvTeAdjRef <- readGDX(gdx_ref, name = c("vm_costInvTeAdj", "v_costInvTeAdj"),
field = "l", format = "first_found")[, ttot, ]
vm_deltaCapRef <- readGDX(gdx_ref, name = c("vm_deltaCap"),
field = "l", format = "first_found")[, ttot, ]

vm_costInvTeDir <- modifyInvestmentVariables(vm_costInvTeDir, vm_costInvTeDirRef, cm_startyear)
vm_costInvTeAdj <- modifyInvestmentVariables(vm_costInvTeAdj, vm_costInvTeAdjRef, cm_startyear)
vm_deltaCap <- modifyInvestmentVariables(vm_deltaCap, vm_deltaCapRef, cm_startyear)
} else {
vm_costInvTeDir <- modifyInvestmentVariables(vm_costInvTeDir)
vm_costInvTeAdj <- modifyInvestmentVariables(vm_costInvTeAdj)
vm_deltaCap <- modifyInvestmentVariables(vm_deltaCap)
}

vm_demPe <- readGDX(gdx, name = c("vm_demPe", "v_pedem"), field = "l", restore_zeros = FALSE, format = "first_found")
v_investcost <- readGDX(gdx, name = c("vm_costTeCapital", "v_costTeCapital", "v_investcost"), field = "l", format = "first_found")[, ttot, ]
vm_cap <- readGDX(gdx, name = c("vm_cap"), field = "l", format = "first_found")
Expand Down

0 comments on commit 939d7e7

Please sign in to comment.