clusterPlot: Plot a flow-based domain of a typical day

View source: R/graphs.R

clusterPlotR Documentation

Plot a flow-based domain of a typical day

Description

For a given hour, plot the flow-based domain of one typical day along with the other flow-based domains it represents (i.e. other domains of the same cluster).

Usage

clusterPlot(data, country1, country2, hour, dayType,
  typicalDayOnly = FALSE, ggplot = FALSE, width = "420px",
  height = "410px", xlim = c(-10000, 10000), ylim = c(-10000, 10000),
  export = T)

Arguments

data

data.table results from the clustering, output data from clusterTypicalDaysForOneClass

country1

character, name of the country whose net position is in the x axis (BE, FR, DE or NL)

country2

character, name of the country whose net position is in the y axis (BE, FR, DE or NL)

hour

numeric, hour of the plotted domain

dayType

numeric, typical flow-based day identifier

typicalDayOnly

logical if TRUE, plot only the domain of the typical day and not the other domains of the cluster

ggplot

logical should ggplot package be used (static graph) instead of rAmCharts (dynamic graph)

width

character, for rAmCharts only. Default to "420px" (set to "100/100" for dynamic resize)

height

character, for rAmCharts only. Default to "410px" (set to "100/100" for dynamic resize)

xlim

numeric, limits of x-axis (default = c(-10000, 10000))

ylim

numeric, limits of x-axis (default = c(-10000, 10000))

export

logical If you want to have the possibility to export your graphic (if true in rmarkdown, can return a blank html)

Examples


## Not run: 

# classification result
clusterTD <- readRDS(system.file("testdata/allTypeDaytest.rds",package = "fbClust"))

clusterPlot(clusterTD, "FR", "DE", 3, 1, FALSE, FALSE)
clusterPlot(clusterTD, "ptdfFR", "DE", 3, 1, FALSE, TRUE)
clusterPlot(clusterTD, "FR", "ptdfDE", 3, 1, TRUE, TRUE)
clusterPlot(clusterTD, "ptdfFR", "ptdfDE", 3, 1, TRUE, FALSE)


## End(Not run)


rte-antares-rpackage/fbClust documentation built on July 4, 2023, 12:06 a.m.