Hi <@U031KHZH06B> I have a question about <https:/...
# general
Hi @fede I have a question about https://nixtla.github.io/statsforecast/models.html#simpleexponentialsmoothingoptimized. Is this function a replica of HoltWinters in R or somewhat different. Is there a way to access optimized alpha from the function run like in R? I am trying to run HoltWinters in R on the same data to match the R output, is sesopt the best choice to match R output?
hey @Valeriy! The easiest way to recover R’s simple exponential smoothing (ses) is to call
with only additive errors (
). Here’s an example of how to recover the parameters (the first one corresponds to
👍 1
That’s great many thanks @fede (nixtla) (they/them)
Hi @fede (nixtla) (they/them) I am trying to replicate R result for this real time series [5,6,3,2,6,3,9] the alpha produced by HoltWinters from R is 6.610696e-05 and this is the result of fit in R [5.0000, 5.0001, 4.9999, 4.9997, 4.9998, 4.9997, 4.9999]. Using the suggested code I am getting a different alpha 1.00000000e-04 and I guess different result. Do you reckon exact replication is possible using one of Nixtla models? Also how does one obtain predictions in sample for the above example? I have tried predict_in_sample() that i used for SimpleExponentialSmoothingOptimized but for AutoETS it did not seem to work
@Mariana Menchero: could you try to replicate?
Sure, I'm on it.
@Mariana Menchero: while you figure this out, could yo create a github issue so we have track of this.
sure, will do
@Mariana Menchero @fede (nixtla) (they/them) @Max (Nixtla) I wonder if there is a way to extract alpha from SES Optimized similar to what Fede shared for ANN model. Getting alpha back from all exponential smoothing is very important. Our devs say currently there doesn’t seem that it is able to return alpha at the moment.
Yes, that's correct. And I agree. Getting the alpha is an important feature worth including in the exponential smoothing models.
Hi @Valeriy I started to review this issue, but I haven't been able to replicate your result. Using the forecast R package v 8.16, the Holt-Winters function hw( ) returns an error (it says that frequency should be greater than one) and the Holt function Holt( ) returns alpha = 0.6075. Hence, - Is the frequency of the time series 1? - What function did you use to obtain the values you mentioned before?
Hi @Mariana Menchero HoltWinters in R, frequency 52, both beta and gamma set to False
Our devs used this setup which should reproduce the numbers
If difficult, don’t spend time on it please, we put Nixtla one as replacement for now but would be great to have alpha returned added to future functionality releases if possible please
Ok, thank you. I was using the Holt-Winters function from the forecast package, but now I see that it should the Holt-Winters function from stats. And yes, we're looking into returning the alpha because we agree that it's an important functionality to have.
👍 2