Code Monkey home page Code Monkey logo

Comments (4)

AdrianAntico avatar AdrianAntico commented on May 14, 2024

Currently, AutoTS() runs a single series at a time. You should supply a data.table with a date column and a target column (in that order), like the example in the help file. If you want to run through multiple series, create a loop and subset the data before each AutoTS() run.

This works for me:

data <- structure(list(zadnja = c(421, 425, 432, 415, 414, 409.99, 407, 
                                  415, 424.99, 432, 425, 433, 428, 428.99, 425, 425, 420, 420, 
                                  420, 419.98, 415, 410, 407, 407.5, 399.98, 400.05, 380, 400, 
                                  394.99, 389.98, 395.05, 381.5, 385, 395.9, 383, 376, 390, 385.01, 
                                  385, 379, 375.1, 380, 378.99, 368.99, 355.75, 367.97, 370, 376, 
                                  386.98, 392), index = structure(c(13917, 13920, 13921, 13922, 
                                                                    13923, 13924, 13927, 13928, 13929, 13930, 13931, 13934, 13935, 
                                                                    13936, 13937, 13938, 13941, 13942, 13943, 13944, 13945, 13948, 
                                                                    13949, 13950, 13951, 13952, 13955, 13956, 13957, 13958, 13963, 
                                                                    13964, 13965, 13966, 13969, 13970, 13971, 13972, 13973, 13976, 
                                                                    13977, 13978, 13979, 13980, 13983, 13984, 13985, 13986, 13987, 
                                                                    13990), class = "Date")), row.names = c(NA, -50L), index_quo = ~index, index_time_zone = "UTC", class = c("tbl_time", 
                                                                                                                                                                              "tbl_df", "tbl", "data.frame"))

data <- data.table::as.data.table(data)
data.table::setcolorder(data, c(2,1))

xx <- RemixAutoML::AutoTS(data,
                          TargetName       = "zadnja",
                          DateName         = "index",
                          FCPeriods        = 1,
                          HoldOutPeriods   = 1,
                          EvaluationMetric = "MAPE",
                          TimeUnit         = "day",
                          Lags             = 1,
                          SLags            = 1,
                          NumCores         = 4,
                          SkipModels       = c("NNET","TBATS","ETS","TSLM","ARFIMA","DSHW"),
                          StepWise         = TRUE,
                          TSClean          = FALSE,
                          ModelFreq        = TRUE,
                          PrintUpdates     = FALSE)

P.S. I keep the code in a single file because it's easier for me to develop that way. I understand it's more challenging to find specific code blocks that way and I'll be splitting them up eventually, when development slows down.

from autoquant.

AdrianAntico avatar AdrianAntico commented on May 14, 2024

I would like to add that I added in the functionality to remove all extraneous columns you may put in your data along with ensuring the ordering of columns are correct.

from autoquant.

MislavSag avatar MislavSag commented on May 14, 2024

Ok, it works now.

Thanks.

It would be to incorporate multivariate models in the future.

from autoquant.

AdrianAntico avatar AdrianAntico commented on May 14, 2024

You should check out AutoCatBoostCARMA(). It's a multivariate catboost forecasting function. It utilizes calendar, trend, and ARMA variables, and replicates an ARMA forecasting process. I tested it recently on some Walmart store / department data and was able to generate forecasts for 2660 store / dept's in about 15 minutes on GPU.

You need to have your data in long format - that is, you need a date column, values column, and categorical columns such that, by filtering for a unique set of factor levels you will have an individual series. So basically, stacked data.

from autoquant.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.