Hi there,
I am doing a time series smoothing work and want to get the deseasonalized series.
I find that the stata official command to perform holt-winters method —— tssmooth shwinters can only store initial and final year season terms, how can I get season terms in all periods?
I am doing a time series smoothing work and want to get the deseasonalized series.
I find that the stata official command to perform holt-winters method —— tssmooth shwinters can only store initial and final year season terms, how can I get season terms in all periods?
Code:
* Example generated by -dataex-. For more info, type help dataex clear input float time int year byte quarter double gdp_real_05 188 2007 1 5.3480300000000005 189 2007 2 5.92168 190 2007 3 6.10994 191 2007 4 6.73992 192 2008 1 5.96403 193 2008 2 6.56999 194 2008 3 6.69194 195 2008 4 7.22133 196 2009 1 6.34319 197 2009 2 7.109039999999999 198 2009 3 7.40225 199 2009 4 8.078510000000001 200 2010 1 7.1168 201 2010 2 7.874689999999999 202 2010 3 8.13667 203 2010 4 8.88211 204 2011 1 7.596957000000001 205 2011 2 8.565657 206 2011 3 8.972157000000001 207 2011 4 9.920089 208 2012 1 8.212311 209 2012 2 9.225213 210 2012 3 9.645069 211 2012 4 10.723616 212 2013 1 8.861083 213 2013 2 9.926328999999999 214 2013 3 10.407029 215 2013 4 11.549334 216 2014 1 9.525665 217 2014 2 10.68073 218 2014 3 11.156335 219 2014 4 12.392436 220 2015 1 10.201986999999999 221 2015 2 11.439061 222 2015 3 11.937279 223 2015 4 13.247514 224 2016 1 10.905924 225 2016 2 12.216918 226 2016 3 12.749013 227 2016 4 14.161592 228 2017 1 11.669339 229 2017 2 13.072102000000001 230 2017 3 13.628695 231 2017 4 15.124581 232 2018 1 12.474523 233 2018 2 13.974077 234 2018 3 14.541818 235 2018 4 16.107678 236 2019 1 13.260418 237 2019 2 14.812522 238 2019 3 15.399785000000001 239 2019 4 17.041923999999998 240 2020 1 12.345449 241 2020 2 15.27171 242 2020 3 16.138975 243 2020 4 18.132607 244 2021 1 14.654048000000001 245 2021 2 16.539262 246 2021 3 16.978202 247 2021 4 18.912309 248 2022 1 15.357442 249 2022 2 16.605419 250 2022 3 17.640351000000003 251 2022 4 19.460766 252 2023 1 16.048527 253 2023 2 17.65156 254 2023 3 18.504729 255 2023 4 20.472726 end format %tq time