diff --git a/R/nowcast.R b/R/nowcast.R index a0f05f1..311861a 100644 --- a/R/nowcast.R +++ b/R/nowcast.R @@ -164,7 +164,7 @@ nowcast <- function(formula, data, r = NULL, q = NULL, p = NULL, method = 'EM', if(!is.matrix(blocks)){blocks <- as.matrix(blocks)} # determine the number of blocks - blocks <- as.matrix(blocks) # variables should be rows, columns the blocks + blocks <- as.matrix(blocks,ncol=ncol(blocks)) # variables should be rows, columns the blocks n_blocks <- dim(blocks)[2] x <- ts(model.frame(formula, data, na.action = NULL), start = start(data), frequency = frequency(data))