Análisis descriptivo de Series Cronológicas

The Camtasia Studio video content presented here requires a more recent version of the Adobe Flash Player. If you are using a browser with JavaScript disabled please enable it now. Otherwise, please update your version of the free Flash Player by downloading here.



En este video se muestra como funciona el menu correspondiente al análisis descriptivo de series cronológicas. Así, se trabaja con una serie de tiempo donde se recoge información correspondiente al número de víctimas mensuales (medidas en miles) en las carreteras españolas durante los años 1986 a 2010 (datos).

En primer lugar se calcula la tendencia de la serie por el método de las medias móviles. Obteniéndose además la representación de la serie original:

Representación serie original

y la representación de la serie original y suavizada (en rojo):

Representación serie original y suavizada

Podemos observar que el número de víctimas aumenta a mediados del año y disminuye al principio del mismo. Además, la tendencia de los últimos años es claramente decreciente (a partir de la observación 250 aproximadamente).

A continuación se procede a desestacionalizar la serie y obtener los índices de variación estacional. En primer lugar, usando el método de las medias móviles:

$`Índices Variación Estacional`
          [,1]      [,2]     [,3]      [,4]     [,5]     [,6]    [,7]     [,8]     [,9]     [,10]     [,11]     [,12]
[1,] 0.8414827 0.7809224 0.906268 0.9416423 0.979274 1.013640 1.25412 1.372269 1.022816 0.9830074 0.9103511 0.9942068

$`Serie Desestacionalizada`
          [,1]     [,2]     [,3]     [,4]     [,5]     [,6]     [,7]     [,8]     [,9]    [,10]    [,11]    [,12]
 [1,] 5.792157 5.516553 6.670212 5.512709 6.603872 6.620695 7.020061 7.848313 6.707952 6.454682 6.816052 7.005585
 [2,] 6.584806 6.695928 6.769521 7.167265 7.410592 7.482934 7.977705 8.620756 7.513571 6.846337 7.001694 7.179593
 [3,] 7.354875 6.977646 7.419439 7.812946 7.505560 7.894323 8.287085 8.318337 7.995574 7.957213 7.882673 7.858526
 [4,] 8.111872 7.813837 8.518451 7.725864 8.492005 7.785803 8.806972 8.586506 7.899760 7.817845 7.632220 7.285204
 [5,] 7.342992 7.560290 7.136962 7.657897 6.797893 7.026164 7.752846 7.657388 7.982864 7.092520 7.389457 7.238936
 [6,] 6.627588 6.552508 7.063032 6.235914 6.683523 7.123832 7.272828 7.645729 7.396248 6.500459 7.104951 6.751110
 [7,] 6.299595 6.530739 6.560973 6.215736 6.782576 5.399354 5.594361 6.376299 5.730259 5.807687 5.238638 5.932367
 [8,] 5.825432 5.123429 5.073554 5.833425 5.437702 5.322403 5.739482 5.926679 5.618802 5.875846 4.576256 5.056292
 [9,] 5.460600 5.015863 4.831904 4.614279 4.952648 5.011642 5.515421 5.433335 5.463349 5.031498 5.154055 5.315795
[10,] 5.508135 5.453807 5.037141 6.181753 5.313120 5.107337 6.033712 5.635191 5.954151 5.209523 5.493485 5.624584
[11,] 5.123100 5.511431 5.514925 5.672005 5.561263 5.708142 5.497879 5.755429 5.630535 5.469948 5.498977 5.629613
[12,] 5.039914 4.914701 6.128430 4.967916 5.696056 5.467425 5.206040 6.056391 5.251190 5.319390 5.965830 5.704044
[13,] 5.858707 6.186274 6.127327 6.488664 6.318967 6.313880 6.264950 6.831020 6.657112 6.734435 7.044535 6.632423
[14,] 6.802279 6.794529 6.519043 6.606543 6.605914 6.352355 6.706694 6.421479 6.927933 6.780213 6.117420 6.280383
[15,] 6.916364 6.651109 6.519043 7.381784 6.544644 6.274418 6.671610 6.189746 6.488949 6.663225 6.189920 6.771227
[16,] 6.937754 6.771480 6.844554 7.165141 6.199490 6.617735 6.445156 6.215252 6.749015 6.562514 6.743552 6.779273
[17,] 6.135599 6.412929 7.044274 5.954490 6.472141 6.993608 6.390138 6.231283 6.368693 6.733418 7.141201 6.768209
[18,] 6.695325 6.708733 6.918483 7.072749 6.955152 7.330020 6.708289 6.974578 7.107829 7.370239 7.234571 6.862757
[19,] 6.634718 7.085211 6.096431 6.348483 6.526263 6.635493 5.844735 5.719722 5.785988 6.580825 6.124011 6.089276
[20,] 5.994182 6.313047 6.132844 5.729352 6.306713 6.430292 5.918891 5.227836 5.765456 6.564548 6.263517 6.206958
[21,] 7.864690 7.313147 7.253925 7.420015 6.848951 6.722309 5.810448 5.347346 6.288522 6.847354 7.086277 6.825541
[22,] 6.886654 7.159482 7.099445 6.832743 6.966385 6.968945 6.560775 5.807897 6.506548 6.561497 6.857794 6.220034
[23,] 6.446954 6.703611 6.258634 5.810062 6.030998 5.893612 5.361528 5.044199 5.464327 5.837189 5.865869 5.802616
[24,] 5.708971 5.816199 5.666094 5.408636 5.404003 5.617380 5.236341 4.779673 5.082049 5.367202 5.651666 5.786522
[25,] 5.441586 5.295021 4.824180 4.902074 5.185474 5.431910 5.127898 4.429159 5.040986 5.802601 5.630795 5.065344

Obteniéndose también la representación de la serie original y la desestacionalizada:

Repesentación de la serie original y la desestacionalizada

Y por último, usando el método de regresión:

$`Índices Variación Estacional`
          [,1]      [,2]      [,3]      [,4]      [,5]     [,6]     [,7]     [,8]     [,9]     [,10]     [,11]     [,12]
[1,] 0.8386307 0.7763826 0.9080547 0.9363672 0.9797545 1.014238 1.256466 1.369344 1.024303 0.9877897 0.9153625 0.9933072

$`Serie Desestacionalizada`
          [,1]     [,2]     [,3]     [,4]     [,5]     [,6]     [,7]     [,8]     [,9]    [,10]    [,11]    [,12]
 [1,] 5.811855 5.548811 6.657088 5.543765 6.600633 6.616789 7.006952 7.865082 6.698215 6.423432 6.778735 7.011930
 [2,] 6.607199 6.735082 6.756201 7.207642 7.406958 7.478519 7.962807 8.639176 7.502665 6.813191 6.963361 7.186095
 [3,] 7.379887 7.018447 7.404841 7.856960 7.501879 7.889665 8.271610 8.336111 7.983968 7.918690 7.839517 7.865643
 [4,] 8.139459 7.859527 8.501691 7.769388 8.487841 7.781209 8.790525 8.604853 7.888293 7.779996 7.590435 7.291803
 [5,] 7.367963 7.604498 7.122919 7.701038 6.794559 7.022019 7.738368 7.673750 7.971277 7.058183 7.349001 7.245493
 [6,] 6.650126 6.590823 7.049135 6.271044 6.680245 7.119629 7.259247 7.662065 7.385512 6.468988 7.066053 6.757225
 [7,] 6.321018 6.568926 6.548064 6.250753 6.779249 5.396168 5.583914 6.389923 5.721941 5.779570 5.209958 5.937740
 [8,] 5.845243 5.153387 5.063572 5.866288 5.435035 5.319263 5.728764 5.939342 5.610646 5.847399 4.551202 5.060872
 [9,] 5.479170 5.045193 4.822397 4.640273 4.950220 5.008685 5.505121 5.444945 5.455419 5.007139 5.125838 5.320610
[10,] 5.526866 5.485698 5.027230 6.216578 5.310514 5.104323 6.022445 5.647231 5.945508 5.184302 5.463409 5.629678
[11,] 5.140522 5.543659 5.504074 5.703959 5.558535 5.704774 5.487612 5.767727 5.622362 5.443466 5.468871 5.634712
[12,] 5.057053 4.943439 6.116372 4.995903 5.693263 5.464199 5.196319 6.069331 5.243567 5.293637 5.933168 5.709211
[13,] 5.878630 6.222448 6.115271 6.525218 6.315868 6.310154 6.253251 6.845616 6.647449 6.701831 7.005967 6.638430
[14,] 6.825412 6.834259 6.506216 6.643761 6.602674 6.348607 6.694170 6.435200 6.917877 6.747388 6.083928 6.286072
[15,] 6.939884 6.690001 6.506216 7.423370 6.541435 6.270716 6.659151 6.202972 6.479530 6.630966 6.156031 6.777360
[16,] 6.961348 6.811075 6.831087 7.205506 6.196450 6.613831 6.433121 6.228532 6.739219 6.530742 6.706632 6.785414
[17,] 6.156464 6.450428 7.030414 5.988035 6.468968 6.989482 6.378205 6.244598 6.359448 6.700819 7.102104 6.774340
[18,] 6.718094 6.747962 6.904871 7.112594 6.951742 7.325695 6.695762 6.989480 7.097511 7.334557 7.194964 6.868973
[19,] 6.657281 7.126641 6.084436 6.384247 6.523063 6.631578 5.833821 5.731943 5.777589 6.548965 6.090483 6.094791
[20,] 6.014566 6.349962 6.120777 5.761628 6.303620 6.426498 5.907838 5.239007 5.757087 6.532767 6.229226 6.212580
[21,] 7.891435 7.355910 7.239652 7.461816 6.845592 6.718343 5.799598 5.358772 6.279394 6.814204 7.047481 6.831724
[22,] 6.910074 7.201347 7.085477 6.871236 6.962969 6.964833 6.548524 5.820307 6.497103 6.529730 6.820249 6.225667
[23,] 6.468878 6.742810 6.246320 5.842793 6.028041 5.890135 5.351516 5.054977 5.456395 5.808929 5.833754 5.807871
[24,] 5.728385 5.850209 5.654946 5.439105 5.401353 5.614066 5.226562 4.789886 5.074672 5.341218 5.620724 5.791763
[25,] 5.460091 5.325982 4.814688 4.929690 5.182931 5.428705 5.118322 4.438623 5.033668 5.774509 5.599967 5.069932

Los índices de variación estacional confirman las suposiciones que se observaban a partir de la representación gráfica del inicio. El número de víctimas aumenta en los meses del verano (especialmente en julio y agosto) y disminuye en los primeros meses del año (especialmente enero y febrero). Por tanto, para poder interpretar correctamente la serie, es necesario desestacionalizarla.