tidyverts / tidyverts/fabletools

Error: Problem with `mutate()` column `ols`. ℹ `ols = (function (object, ...) ...`. x variable names are limited to 10000 bytes

Open
#336 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
R
Stars
98
Forks
37
PR merge metrics
No merged PRs in 30d

Description

Hello,

I am receiving an error when using the reconcile() function. I am performing hierarchical forecasting on a data set with many hierarchical levels.

tic()

fit <- EMEA_shipments_08 %>%
  model(arima = ARIMA(ZCOPASMG))

toc()

tic()

fc <- fit %>%
  reconcile(
    ols = min_trace(arima, method="ols")
    #wlsv = min_trace(arima, method="wls_var"),
    #wlss = min_trace(arima, method="wls_struct"),
    #mint_c = min_trace(ets, method="mint_cov"),
    #mint_s = min_trace(arima, method="mint_shrink")
  ) %>%
  forecast(h = "2 years")

Error: Problem with `mutate()` column `ols`.
ℹ `ols = (function (object, ...) ...`.
x variable names are limited to 10000 bytes
Run `rlang::last_error()` to see where the error occurred.

I suspect this error is occurring because I have 7 columns in my hierarchy, with thousands of of levels for these columns. I know this is not reproducible code, but I think the description of my problem is clear.

Is there a maximum size to a hierarchy that the reconcile function is intended to work with? Is it possible that the source code will be changed to accommodate larger hierarchies?

I am curious to learn more about this topic, and I love the fable package and its functionality.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the supplied reconcile() call using min_trace(..., method="ols") and inspect rlang::last_error() to locate where the variable-name limit is reached. Reproduce the failure with a hierarchy resembling the reported seven columns and thousands of levels. Done means establishing whether the hierarchy exceeds a supported limit and, if a code change is appropriate, adding coverage for the failing case.

Written by the indexing model from the issue text.

Assessment

Tech stack
r
Domain
data
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.