Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

decomposition result of multiAirlineDecomposition #12

Open
AQLT opened this issue Nov 12, 2023 · 0 comments
Open

decomposition result of multiAirlineDecomposition #12

AQLT opened this issue Nov 12, 2023 · 0 comments

Comments

@AQLT
Copy link

AQLT commented Nov 12, 2023

I think there is an error in the output of the decomposition of multiAirlineDecomposition() (more exported components than expected)
https://github.com/rjdemetra/rjd3highfreq/blob/010dd15052736669018b9dd8c0ed58ff1220a2f3/R/jd3_fractionalairline.R#L298-L301
I think the irregular is the last object but then I don't know what is the penultimate.
Moreover, I don't find the SA series using y and the seasonal component

amb.multi <- rjd3highfreq::multiAirlineDecomposition(
  y = forecast::taylor,
  periods = c(2 * 24, 2*24*7),
  log = FALSE, ndiff = 2)
decomp <- amb.multi$decomposition
# Last name not defined
names(decomp)
#> [1] "y"      "y_time" "sa"     "t"      "s_48"   "s_336"  "i"      NA
all.equal((decomp$t + decomp$i), decomp$sa)
#> [1] "Mean relative difference: 0.004231776"
all.equal((decomp$t + decomp[[8]]), decomp$sa)
#> [1] TRUE
# Should it be true ?
all.equal((decomp$y - (decomp$s_48 + decomp$s_336)), decomp$sa)
#> [1] "Mean relative difference: 0.004299653"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant