In the Stan User’s Guide v2.32, the last line in Section 2.4 recommends adding a constraint on the AR coefficient phi to ensure stationarity. But in Section 2.1, the same constraint on the AR coefficient (beta in this case) is given but “… is not recommended. If the data are not well fit by a stationary model it is best to know this. Stationary parameter estimates can be encouraged with a prior favoring values of beta near zero.”
Thanks. I added an issue to the documentation so we remember to clarify.
If you know you’re dealing with a stationary process, the constraint can make sense and even help guide the fit (it’ll keep all the uncertainty within stationary parameter values). If you don’t know you have a stationary process, this can be dangerous and will likely lead to instability in fit due to probability mass bunching up at constraint boundaries. So if you’re unsure if your data are from a stationary process, it can help to not enforce the constraints and see what the data implies for a fit.