I am using ucm()
function of package rucm
in R. I am trying to predict sales where units is dependent variable and month,day,temperature are independent variables. While running code I am getting following error
Code:
UCM_test_reg<-ucm(units~month+day,train_data, irregular = TRUE, level = TRUE,season = TRUE,season.length = 7)
Error :
Error in modelH$Q[find.level - length(indep.var), find.level - length(indep.var), :
subscript out of bounds
Month and day are categorical variables and temperature is continuous.Is it because of using categorical variable? I would appreciate any kind of help.
Thanks in advance.