createCorridor | R Documentation |
Create a corridor around the main diagonal. For long time series it may not make sense to evaluate recurrences on the longest time scales.
createCorridor(mat, lower, upper, value = NA, silent = TRUE)
mat |
A Matrix |
lower |
Lower diagonal to be included in the corridor (should be |
upper |
Upper diagonal to be included in the corridor (should be |
value |
A single value to replace all values outside the corridor (default = |
silent |
Operate in silence, only (some) warnings will be shown (default = |
A matrix in which the values outside the corridor have been replaced
Fred Hasselman
Other Distance matrix operations (recurrence plot):
bandReplace()
,
mat_di2bi()
,
mat_di2ch()
,
mat_di2we()
,
mat_hamming()
,
rp()
,
rp_lineDist()
,
rp_nzdiags()
,
rp_plot()
,
rp_size()
# Create a 10 by 10 matrix
library(Matrix)
m <- Matrix(rnorm(10),10,10)
createCorridor(m,-7,7,0) # Set diagonals 10 9 and 8 to 0.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.