Behavior of GaussianRandomWalk with tensor parameters #5972
Replies: 5 comments
-
The GRW expects a single mu/sigma per independent series. |
Beta Was this translation helpful? Give feedback.
-
If you want to model a RW with changing mu you will have to do it manually. If you difference your data, you can use a normal likelihood. |
Beta Was this translation helpful? Give feedback.
-
Thanks for your feedback @ricardoV94 ndim_supp = 1
ndims_params = [0, 0, 0, 0] where other RV like the ones provided in aesara would rather be like ndim_supp = 0
ndims_params = [0, 0] Is this how I can spot the difference ? |
Beta Was this translation helpful? Give feedback.
-
Yes, that is where the difference comes from. It was a simplifying choice to make the distribution be a vector one ( Your interpretation of the GRW is equally valid, and perhaps more general. But it would make it more hazardous to write down batched GRW, as the user would need to know/remember to broadcast mu and sigma along the last axis if they didn't mean it to vary within the same series (if This guide explains the distribution dimensionality logic: https://www.pymc.io/projects/docs/en/stable/learn/core_notebooks/dimensionality.html Anyway, you are free to adapt the source code and implement the version that matches your interpretation. If other users feel the need for it, we can even consider adding it to the codebase or replace the current one altogether. |
Beta Was this translation helpful? Give feedback.
-
Follow up discussion in #6090 |
Beta Was this translation helpful? Give feedback.
-
I was trying to look after some trend changes in random walks, using a model similar to the one below.
When using a Normal RV for data, things work fine. The break location and the different mu/sigma are estimated properly.
Now, when using the random walk and observing the cumsum values, everything breaks.
Somehow, it seems that GaussianRandowWalk returns matrices instead of vectors during a run, when passing tensors as mu and sigma.
I assume I am missing something obvious. I tried using pandas.Series as observed data as well, to no avail.
Please provide a minimal, self-contained, and reproducible example.
Please provide the full traceback.
Complete error traceback
Please provide any additional information below.
Versions and main components
Beta Was this translation helpful? Give feedback.
All reactions