r - Amplitude of seasonal arima point forecast converges to zero -


here data.

   jan feb mar apr may jun jul aug sep oct nov dec 1   64  63  77 118 174 229 262 242 185 165  82  51 2   89  38  51 103 164 217 239 227 188 156  83  19 3   42  39  66 117 166 219 249 233 199 154  68  49 4   45  41  64 130 165 233 258 236 197 119  84  39 5   55  50  77 120 196 222 250 236 196 149  84  52 6   21  58  64 139 162 221 245 227 211 159  75  29 7    8  30  79 135 178 201 265 252 200 146  73   3 8    9  50  55 107 158 222 242 236 192 152  89  80 9    0  48  66 146 178 239 242 225 212 122  91  55 10   2  -2  46 126 170 204 258 235 195 142  99 -14 11  15  36  69 133 192 232 248 254 212 158  82  54 12  33  38  11 152 167 221 234 249 203 142  95   3 13  -6  47  84 106 159 217 255 240 230 144  96  29 14  20  23  58 125 185 219 227 233 185 142  70   9 15   4  -3  92 125 164 219 241 227 179 147  96   0 16  38  22  76 111 181 220 245 224 198 121  98  56 17   8  30  47 101 186 201 235 235 211 130  87  45 18   2  21  81 103 162 211 247 246 198 133  98  37 19  53  15  59 121 141 216 247 240 180 129  55  40 20  -1  -2  88 125 176 238 259 250 191 147  96  22 21   6  13  41 128 171 233 248 237 199 134  70  27 22 -19  20  46 117 180 219 242 238 216 157  93  30 23  -5  35  56 106 161 229 243 235 218 183  90  78 24  42  27  68 115 174 207 249 235 210 127  89  80 25  31  28 106 133 160 231 238 242 210 144  88  48 26  52  18  77 131 164 202 240 237 194 122  84  48 27  41  43  62  94 184 224 241 249 201 160 116  46 28  10  78  96 137 166 235 247 237 196 121  51  15 29 -45  19  93 134 180 216 264 263 229 140 115  42 30  11 -26  60 127 177 235 249 268 201 131  98  42 31  16 -31  83 118 182 202 238 240 209 134 112  58 32  27   4  61 137 187 214 258 256 221 134  74  26 33 -19  44  53 138 164 234 243 219 197 129  88  32 34 -12  33  70 110 193 217 253 229 201 137 102  69 35  26  30  84 114 164 214 252 247 210 161 110  45 36  13  77  58 120 172 234 243 246 190 177  79  79 37 -15  29  86 147 186 211 249 238 206 161 133  24 38  12  24  80 121 186 226 264 228 203 153  90  45 39  10  10  71 111 181 232 260 242 213 114  99  51 40  -4  32  75 114 174 223 259 256 192 113  97  31 41  45  30  77 117 170 242 244 239 212 154  83 -24 42  63  68  90 124 166 227 257 240 190 161  99  68 43  34  49  85 135 202 225 254 246 197 143  91  52 44  30  41  62 119 154 204 249 225 207 123  95  46 45  42   7  54 119 180 225 269 247 208 132  90  23 46  -4  25  77 153 156 243 270 229 197 130 111  66 47  46  23  88 131 180 230 270 254 211 155  62  11 48  14  24  46 122 164 227 238 230 204 142  56  57 49  22  59  80 110 157 210 252 233 205 147  90  48 50  63  63  84 121 168 216 247 246 226 147  87  57 51  49  45  63 124 177 219 268 246 209 136 110  54 52  16  49  98 121 186 232 230 235 197 146  71   9 53  26  46  58 126 167 222 216 239 177 126  96  59 54  38  40  78 134 161 217 244 244 204 143  75  24 55 -16   8  76 110 144 209 241 241 205 124 104  31 56 -14  18  74 122 204 208 241 227 200 128  84  35 57  17  26  41 114 135 215 249 244 206 144  93  17 58  57  22  61 122 159 211 249 239 182 128 102  57 59  43 -11  70 106 162 212 238 239 196 173  70  40 60  18  41  78 127 155 231 242 217 203 123  71  57 61  -5  33  61 125 178 217 237 252 195 146 109  36 62   8  -1  89 142 190 252 266 250 216 149  88   0 63  -2  47  71 151 196 244 275 249 225 149 116  75 64  53  59 122 135 206 232 282 260 212 163  80  83 65  45  40  57 140 188 244 272 241 208 169  88  63 

auto.arima() spit out arima(200)(200)[12]. forecast() @ large h of model gave me point forecast converges zero.

i put image in here, don't have enough points yet. sorry.

please correct me if i'm wrong, shouldn't forecast of type of data have top peaks continue trend of top peaks of data , ditto bottom extrema? there significant discontinuity in slope of these 2 trends @ boundary between data , forecast.

if true, can please tell type of model address issue , corresponding method(s) identification?

if not true, can please explain why?

also, couldn't decide whether question more of r question or statistics question, , therefore wasn't sure whether post here or cross validated. figured here safer bet, please let me know if i'm wrong.

thanks in advance!

first, let's see if can reproduce example.

aside note: next time, if print output dput done below , show code using, easier other people reproduce getting.

so these data (a monthly time series):

dput(x) structure(c(64, 63, 77, 118, 174, 229, 262, 242, 185, 165, 82,  51, 89, 38, 51, 103, 164, 217, 239, 227, 188, 156, 83, 19, 42,  39, 66, 117, 166, 219, 249, 233, 199, 154, 68, 49, 45, 41, 64,  130, 165, 233, 258, 236, 197, 119, 84, 39, 55, 50, 77, 120, 196,  222, 250, 236, 196, 149, 84, 52, 21, 58, 64, 139, 162, 221, 245,  227, 211, 159, 75, 29, 8, 30, 79, 135, 178, 201, 265, 252, 200,  146, 73, 3, 9, 50, 55, 107, 158, 222, 242, 236, 192, 152, 89,  80, 0, 48, 66, 146, 178, 239, 242, 225, 212, 122, 91, 55, 2,  -2, 46, 126, 170, 204, 258, 235, 195, 142, 99, -14, 15, 36, 69,  133, 192, 232, 248, 254, 212, 158, 82, 54, 33, 38, 11, 152, 167,  221, 234, 249, 203, 142, 95, 3, -6, 47, 84, 106, 159, 217, 255,  240, 230, 144, 96, 29, 20, 23, 58, 125, 185, 219, 227, 233, 185,  142, 70, 9, 4, -3, 92, 125, 164, 219, 241, 227, 179, 147, 96,  0, 38, 22, 76, 111, 181, 220, 245, 224, 198, 121, 98, 56, 8,  30, 47, 101, 186, 201, 235, 235, 211, 130, 87, 45, 2, 21, 81,  103, 162, 211, 247, 246, 198, 133, 98, 37, 53, 15, 59, 121, 141,  216, 247, 240, 180, 129, 55, 40, -1, -2, 88, 125, 176, 238, 259,  250, 191, 147, 96, 22, 6, 13, 41, 128, 171, 233, 248, 237, 199,  134, 70, 27, -19, 20, 46, 117, 180, 219, 242, 238, 216, 157,  93, 30, -5, 35, 56, 106, 161, 229, 243, 235, 218, 183, 90, 78,  42, 27, 68, 115, 174, 207, 249, 235, 210, 127, 89, 80, 31, 28,  106, 133, 160, 231, 238, 242, 210, 144, 88, 48, 52, 18, 77, 131,  164, 202, 240, 237, 194, 122, 84, 48, 41, 43, 62, 94, 184, 224,  241, 249, 201, 160, 116, 46, 10, 78, 96, 137, 166, 235, 247,  237, 196, 121, 51, 15, -45, 19, 93, 134, 180, 216, 264, 263,  229, 140, 115, 42, 11, -26, 60, 127, 177, 235, 249, 268, 201,  131, 98, 42, 16, -31, 83, 118, 182, 202, 238, 240, 209, 134,  112, 58, 27, 4, 61, 137, 187, 214, 258, 256, 221, 134, 74, 26,  -19, 44, 53, 138, 164, 234, 243, 219, 197, 129, 88, 32, -12,  33, 70, 110, 193, 217, 253, 229, 201, 137, 102, 69, 26, 30, 84,  114, 164, 214, 252, 247, 210, 161, 110, 45, 13, 77, 58, 120,  172, 234, 243, 246, 190, 177, 79, 79, -15, 29, 86, 147, 186,  211, 249, 238, 206, 161, 133, 24, 12, 24, 80, 121, 186, 226,  264, 228, 203, 153, 90, 45, 10, 10, 71, 111, 181, 232, 260, 242,  213, 114, 99, 51, -4, 32, 75, 114, 174, 223, 259, 256, 192, 113,  97, 31, 45, 30, 77, 117, 170, 242, 244, 239, 212, 154, 83, -24,  63, 68, 90, 124, 166, 227, 257, 240, 190, 161, 99, 68, 34, 49,  85, 135, 202, 225, 254, 246, 197, 143, 91, 52, 30, 41, 62, 119,  154, 204, 249, 225, 207, 123, 95, 46, 42, 7, 54, 119, 180, 225,  269, 247, 208, 132, 90, 23, -4, 25, 77, 153, 156, 243, 270, 229,  197, 130, 111, 66, 46, 23, 88, 131, 180, 230, 270, 254, 211,  155, 62, 11, 14, 24, 46, 122, 164, 227, 238, 230, 204, 142, 56,  57, 22, 59, 80, 110, 157, 210, 252, 233, 205, 147, 90, 48, 63,  63, 84, 121, 168, 216, 247, 246, 226, 147, 87, 57, 49, 45, 63,  124, 177, 219, 268, 246, 209, 136, 110, 54, 16, 49, 98, 121,  186, 232, 230, 235, 197, 146, 71, 9, 26, 46, 58, 126, 167, 222,  216, 239, 177, 126, 96, 59, 38, 40, 78, 134, 161, 217, 244, 244,  204, 143, 75, 24, -16, 8, 76, 110, 144, 209, 241, 241, 205, 124,  104, 31, -14, 18, 74, 122, 204, 208, 241, 227, 200, 128, 84,  35, 17, 26, 41, 114, 135, 215, 249, 244, 206, 144, 93, 17, 57,  22, 61, 122, 159, 211, 249, 239, 182, 128, 102, 57, 43, -11,  70, 106, 162, 212, 238, 239, 196, 173, 70, 40, 18, 41, 78, 127,  155, 231, 242, 217, 203, 123, 71, 57, -5, 33, 61, 125, 178, 217,  237, 252, 195, 146, 109, 36, 8, -1, 89, 142, 190, 252, 266, 250,  216, 149, 88, 0, -2, 47, 71, 151, 196, 244, 275, 249, 225, 149,  116, 75, 53, 59, 122, 135, 206, 232, 282, 260, 212, 163, 80,  83, 45, 40, 57, 140, 188, 244, 272, 241, 208, 169, 88, 63), .tsp = c(1,  65.9166666666667, 12), class = "ts") 

you using auto.arima choose , fit arima model:

require(forecast) fit <- auto.arima(x) fit #arima(2,0,0)(2,0,0)[12] non-zero mean  #coefficients: #         ar1     ar2    sar1    sar2  intercept #      0.0966  0.0883  0.5115  0.4622   139.5995 #s.e.  0.0365  0.0358  0.0316  0.0319    19.8641 #sigma^2 estimated 380.2:  log likelihood=-3440.66 #aic=6893.32   aicc=6893.42   bic=6921.27 

these four-years-ahead forecasts based on fitted model:

p <- forecast(fit, h = 48) p$mean #         jan       feb       mar       apr       may       jun       jul #66  48.57136  49.58209  88.81085 137.47800 194.98741 235.67825 273.12356 #67  49.32090  47.52704  75.44813 138.69951 190.29768 236.99099 269.08370 #68  51.35483  50.90446  83.31537 138.15870 191.12836 233.81640 267.53671 #69  52.74154  51.68213  81.16343 138.44663 189.38580 232.79939 264.87839 #         aug       sep       oct       nov       dec #66 247.10481 208.04427 165.45149  85.66308  74.26293 #67 241.44882 206.21915 166.40985  88.16525  70.78031 #68 241.37739 205.30611 165.26003  88.36498  74.20439 #69 238.72685 203.99562 165.11485  89.62355  74.34615 

display forecasts (without confidence bands illustration):

plot(cbind(x, p$mean), plot.type = "single", type = "n", ylim = c(-50, 315)) lines(x) lines(p$mean, col = "blue") legend("topleft", legend = c("observed data", "forecasts"), lty = c(1, 1),   col = c("black", "blue"), bty = "n") 

forecasts

is get? if so, please explain concerns.

edit 1

according design of these models, forecasts based on information last observations. parameter estimates obtained maximum likelihood based on whole sample forecasts depend on last observations.

for example, in model selected in case, arima(2,0,0)(2,0,0), , given parameter estimates, forecasts function of last 2 observations (regular ar part of model) , 12-th , 24-th last observations (seasonal ar part). if are, say, 60 observations ahead last observation, forecasts depend on previous forecasts rather on observed values. thus, there increasing uncertainty in forecasts, in addition wider confidence intervals, involves forecast values tend converge average of sample data.

in case, wouldn't perform more 4-5 years ahead forecasts.

this may give intuition increasing uncertainty in forecasts go further future , why shouldn't use these models long-term forecasting. if post question @ cross validated may give further insight this.

as seasonal pattern relatively stable, may consider model seasonal dummies. in case, have accept fact seasonal pattern deterministic. trend, deterministic linear trend. example, can try:

sd <- seasonaldummy(x) fit2 <- lm(x ~ 1 + seq_along(x) + sd) summary(fit2) newd <- data.frame(cbind(seq(781, 781+779), sd)) colnames(newd) <- colnames(model.matrix(fit2))[-1] p2 <- predict(fit2, newdata = newd) p2 <- ts(p2, start = c(66, 1), frequency = 12) plot(cbind(x, p2), plot.type = "single", type = "n") lines(x) lines(p2, col = "blue") 

Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -