exchangesStack: Plot the exchanges of an area

Description Usage Arguments Details Value Examples

Description

This function draws a stack representing the evolution of the exchanges of an area with its neighbours. Positive values denotes exports and negative values imports.

Usage

1
2
3
4
5
6
7
8
9
exchangesStack(x, area = NULL, mcYear = "average", dateRange = NULL,
  colors = NULL, main = NULL, ylab = NULL, unit = c("MWh", "GWh",
  "TWh"), compare = NULL, compareOpts = list(),
  interactive = getInteractivity(), legend = TRUE,
  legendId = sample(1e+09, 1), groupId = legendId, legendItemsPerRow = 5,
  width = NULL, height = NULL, xyCompare = c("union", "intersect"),
  h5requestFiltering = list(), stepPlot = FALSE, drawPoints = FALSE,
  timeSteph5 = "hourly", mcYearh5 = NULL, tablesh5 = c("areas", "links"),
  ...)

Arguments

x

Object of class antaresData created with function readAntares. It is required to contain link data. If it also contains area data with column 'ROW BAL.', then exchanges with the rest of the world are also displayed on the chart.

area

Name of a single area. The flows from/to this area will be drawn by the function.

mcYear

If x, contains multiple Monte-Carlo scenarios, this parameter determine which scenario is displayed. Must be an integer representing the index of the scenario or the word "average". In this case data are averaged.

dateRange

A vector of two dates. Only data points between these two dates are displayed. If NULL, then all data is displayed.

colors

Vector of colors with same length as parameter variables. If variables is an alias, then this argument should be NULL in order to use default colors.

main

Title of the graph.

ylab

Title of the Y-axis.

unit

Unit used in the graph. Possible values are "MWh", "GWh" or "TWh".

compare

An optional character vector containing names of parameters. When it is set, two charts are outputed with their own input controls. Alternatively, it can be a named list with names corresponding to parameter names and values being list with the initial values of the given parameter for each chart. See details if you are drawing a map.

compareOpts

List of options that indicates the number of charts to create and their position. Check out the documentation of compareOptions to see available options.

interactive

LogicalValue. If TRUE, then a shiny gadget is launched that lets the user interactively choose the areas or districts to display.

legend

Logical value indicating if a legend should be drawn. This argument is usefull when one wants to create a shared legend with prodStackLegend

legendId

Id of the legend linked to the graph. This argument is usefull when one wants to create a shared legend with prodStackLegend

groupId

Parameter that can be used to synchronize the horizontal zoom of multiple charts. All charts that need to be synchronized must have the same group.

legendItemsPerRow

Number of elements to put in each row of the legend.

width

Width of the graph expressed in pixels or in percentage of the parent element. For instance "500px" and "100%" are valid values.

height

Height of the graph expressed in pixels or in percentage of the parent element. For instance "500px" and "100%" are valid values.

xyCompare

Use when you compare studies, can be "union" or "intersect". If union, all of mcYears in one of studies will be selectable. If intersect, only mcYears in all studies will be selectable.

h5requestFiltering

Contains arguments used by default for h5 request, typically h5requestFiltering = list(select = "NUCLEAR")

stepPlot

boolean, step style for curves.

drawPoints

boolean, add points on graph

timeSteph5

character timeStep to read in h5 file. Only for Non interactive mode.

mcYearh5

numeric mcYear to read for h5. Only for Non interactive mode.

tablesh5

character tables for h5 ("areas" "links", "clusters" or "disticts"). Only for Non interactive mode.

...

Other arguments for manipulateWidget

Details

Compare argument can take following values :

Value

A htmlwidget of class dygraph. It can be modified with functions from package dygraphs.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
## Not run: 
mydata <- readAntares(links = "all", timeStep = "daily")
exchangesStack(mydata)

# Also display exchanges with the rest of the world
mydata <- readAntares(areas = "all", links = "all", timeStep = "daily")
exchangesStack(mydata)

# Use compare :
exchangesStack(mydata, compare = "mcYear")
exchangesStack(mydata, compare = "area")
exchangesStack(mydata, compare = "unit")
exchangesStack(mydata, compare = "legend")


## End(Not run)

rte-antares-rpackage/bpN documentation built on May 31, 2019, 2:52 p.m.