Plot Cumulative Complexity Peaks
Usage
plotDC_ccp(
df_ccp,
win,
useVarNames = TRUE,
colOrder = TRUE,
useTimeVector = NA,
timeStamp = "31-01-1999",
doPlot = TRUE,
markID = NA,
NAdates = 1:(win - 1),
title = "Critical Instability Plot",
resVariable = "",
subtitle = "",
markIDcolour = "red",
markIDlabel = "Time points of interest marked red",
markIDalpha = 0.5,
xlabel = "Time",
ylabel = "",
trimFirstWin = TRUE
)
Arguments
- df_ccp
A dataframe generated by
dc_ccp()
- win
Size of window in which to calculate Dynamic Complexity. If
win < NROW(df)
the window will move along the time series with a stepsize of1
(default =NROW(df)
)- useVarNames
Use the column names of
df
as variable names in the Complexity Resonance Diagram (default =TRUE
)- colOrder
If
TRUE
, the order of the columns indf
determines the of variables on the y-axis. UseFALSE
for alphabetic/numeric order. UseNA
to sort by by mean value of Dynamic Complexity (default =TRUE
)- useTimeVector
Parameter used for plotting. A vector of length
NROW(df)
, containing date/time information (default =NA
)- timeStamp
If
useTimeVector
is notNA
, a character string that can be passed tolubridate::stamp()
to format the the dates/times passed inuseTimeVector
(default ="01-01-1999"
)- doPlot
If
TRUE
shows a Complexity Resonance Diagram of the Dynamic Complexity and returns an invisibleggplot2::ggplot()
object. (default =FALSE
)- markID
Numeric vector of integers in the range
[length of window, length of timeseries]
. Vertical lines will be drawn at these indices (default =NA
)- NAdates
Should some dates be considered
NA
? Provide a numerical vector with indices, the default is to set1:(win-1)
to NA. (default =1:(win-1)
)- title
A title for the plot.
- resVariable
Variable displayed in the plot.
- subtitle
A subtitle for the plot.
- markIDcolour
Colour of time point markers (default =
"red"
)- markIDlabel
Label added to subtitle explaining time point markers (default =
Time points of interest marked red
)- markIDalpha
Alpha of time point marker colour (default =
.5
)- xlabel
A label for the x-axis.
- ylabel
A label for the y-axis.
- trimFirstWin
Display the first empty window (
1:win-1
)? (default =TRUE
)
See also
Other Dynamic Complexity functions:
dc_ccp()
,
dc_d()
,
dc_f()
,
dc_win()
,
plotDC_lvl()
,
plotDC_res()