View source: R/ctx_node_covlmc.R
covariate_memory | R Documentation |
This function returns the length of the memory of a COVLMC context represented
by a ctx_node_covlmc
object.
covariate_memory(node)
node |
A |
the memory length, an integer
pc <- powerconsumption[powerconsumption$week == 5, ]
dts <- cut(pc$active_power, breaks = c(0, quantile(pc$active_power, probs = c(0.5, 1))))
dts_cov <- data.frame(day_night = (pc$hour >= 7 & pc$hour <= 17))
m_cov <- covlmc(dts, dts_cov, min_size = 10)
ctxs <- contexts(m_cov)
## get all the memory lengths
sapply(ctxs, covariate_memory)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.