compute_margins: Compute upward or downward margins

Description Usage Arguments Value Examples

Description

From Antares results, calculate upward or downward margins for an area.

Usage

1
2
3
4
compute_margins(date, area = "fr", margin = c("upward", "downward"),
  formula_cnes = TRUE, mcYears = "all", virtual_areas = c("lac",
  "pump_d", "turb_d", "pump_w", "turb_w"),
  opts = antaresRead::simOptions())

Arguments

date

Date of the study.

area

Area studied.

margin

Type of margin to compute, upward or downward, can be abbreviated.

formula_cnes

For downward margins, use CNES formula or not.

mcYears

Index of the Monte-Carlo years to import, by default all of them. Passed to readAntares.

virtual_areas

List of virtuals areas.

opts

List of simulation parameters returned by the function antaresRead::setSimulationPath

Value

a list of data.table with 3 slots: data_area, margin_area_solo and margin_area_inter.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
## Not run: 

library(antaresRead)
library(antaresWeeklyMargin)

opts <- setSimulationPath("path/to/study/")

# Upward margins for France
up <- compute_margins(
  date = "2018-06-23",
  area = "fr",
  margin = "upward"
)

# Downward margins
# can be slow - all clusters are read
down <- compute_margins(
  date = "2018-06-23", 
  area = "fr",
  margin = "downward"
)


## End(Not run)

rte-antares-rpackage/antaresWeeklyMargin documentation built on May 16, 2019, 8:15 p.m.