Edit an Antares study before running simulation.
This package provide methods to create (and remove) area, links between them, thermal cluster and binding constraints. These steps maybe usefull before running an Antares simulation.
Install from CRAN:
Or install dev version from GitHub :
# with remotes
remotes::install_github("rte-antares-rpackage/antaresEditObject")
# or with install-github.me service (based on remotes) (Works well with RTE proxy)
source("https://install-github.me/rte-antares-rpackage/antaresEditObject")
# or with devtools
devtools::install_github("rte-antares-rpackage/antaresEditObject")
You need to set the path to an Antares simulation in “input” mode :
Or you can simply create a new study :
Before modifying your simulation, you can save it in an archive :
This will create a .tar.gz
file in your simulation folder.
You can create a new area with :
library("antaresEditObject")
createArea(name = "myarea")
# The new area should appear here :
antaresRead::getAreas()
You can specify the localization of the area on the map, and also color.
There are two helper function for area parameters :
filteringOptions()
for filtering options, like filter-year-by-year
nodalOptimizationOptions()
for nodal optimizations options.You can initialize a cluster with some parameters :
createCluster(
area = "myarea",
cluster_name = "myareacluster",
group = "other",
unitcount = 1,
nominalcapacity = 8400,
`min-down-time` = 0,
`marginal-cost` = 0.010000,
`market-bid-cost` = 0.010000
)
You can edit the settings of an existing cluster :
createLink(
from = "area1",
to = "area2",
propertiesLink = propertiesLinkOptions(
hurdles_cost = FALSE,
transmission_capacities = "enabled"
),
dataLink = NULL
)
You can edit the settings of an existing link :
createBindingConstraint(
name = "myconstraint",
values = matrix(data = c(rep(c(19200, 0, 0), each = 366)), ncol = 3),
enabled = FALSE,
timeStep = "daily",
operator = "both",
coefficients = c("fr%myarea" = 1)
)
pspData <- data.frame(
area = c("a", "b"),
installedCapacity = c(800,900)
)
createPSP(
areasAndCapacities = pspData,
efficiency = 0.75
)
dsrData <- data.frame(
area = c("a", "b"),
unit = c(10,20),
nominalCapacity = c(100, 120),
marginalCost = c(52, 65),
hour = c(3, 7)
)
createDSR(dsrData)
For example, set the output of simulation year by year, and limit the number of Monte-Carlo years to 10 :
You can remove from input folder areas, links, clusters and binding constraints with remove*
functions, e.g. :
First, update general settings to activate time series to generate :
Then run TS-generator:
Launch an Antares simulation from R :