R version 3.0.2 (2013-09-25) -- "Frisbee Sailing" Copyright (C) 2013 The R Foundation for Statistical Computing Platform: i686-pc-linux-gnu (32-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > x <- array(list(119.992 + ,157.302 + ,0.00784 + ,0.00007 + ,0.00554 + ,0.02971 + ,122.4 + ,148.65 + ,0.00968 + ,0.00008 + ,0.00696 + ,0.04368 + ,116.682 + ,131.111 + ,0.0105 + ,0.00009 + ,0.00781 + ,0.0359 + ,116.676 + ,137.871 + ,0.00997 + ,0.00009 + ,0.00698 + ,0.03772 + ,116.014 + ,141.781 + ,0.01284 + ,0.00011 + ,0.00908 + ,0.04465 + ,120.552 + ,131.162 + ,0.00968 + ,0.00008 + ,0.0075 + ,0.03243 + ,120.267 + ,137.244 + ,0.00333 + ,0.00003 + ,0.00202 + ,0.01351 + ,107.332 + ,113.84 + ,0.0029 + ,0.00003 + ,0.00182 + ,0.01256 + ,95.73 + ,132.068 + ,0.00551 + ,0.00006 + ,0.00332 + ,0.01717 + ,95.056 + ,120.103 + ,0.00532 + ,0.00006 + ,0.00332 + ,0.02444 + ,88.333 + ,112.24 + ,0.00505 + ,0.00006 + ,0.0033 + ,0.01892 + ,91.904 + ,115.871 + ,0.0054 + ,0.00006 + ,0.00336 + ,0.02214 + ,136.926 + ,159.866 + ,0.00293 + ,0.00002 + ,0.00153 + ,0.0114 + ,139.173 + ,179.139 + ,0.0039 + ,0.00003 + ,0.00208 + ,0.01797 + ,152.845 + ,163.305 + ,0.00294 + ,0.00002 + ,0.00149 + ,0.01246 + ,142.167 + ,217.455 + ,0.00369 + ,0.00003 + ,0.00203 + ,0.01359 + ,144.188 + ,349.259 + ,0.00544 + ,0.00004 + ,0.00292 + ,0.02074 + ,168.778 + ,232.181 + ,0.00718 + ,0.00004 + ,0.00387 + ,0.0343 + ,153.046 + ,175.829 + ,0.00742 + ,0.00005 + ,0.00432 + ,0.05767 + ,156.405 + ,189.398 + ,0.00768 + ,0.00005 + ,0.00399 + ,0.0431 + ,153.848 + ,165.738 + ,0.0084 + ,0.00005 + ,0.0045 + ,0.04055 + ,153.88 + ,172.86 + ,0.0048 + ,0.00003 + ,0.00267 + ,0.04525 + ,167.93 + ,193.221 + ,0.00442 + ,0.00003 + ,0.00247 + ,0.04246 + ,173.917 + ,192.735 + ,0.00476 + ,0.00003 + ,0.00258 + ,0.03772 + ,163.656 + ,200.841 + ,0.00742 + ,0.00005 + ,0.0039 + ,0.01497 + ,104.4 + ,206.002 + ,0.00633 + ,0.00006 + ,0.00375 + ,0.0378 + ,171.041 + ,208.313 + ,0.00455 + ,0.00003 + ,0.00234 + ,0.01872 + ,146.845 + ,208.701 + ,0.00496 + ,0.00003 + ,0.00275 + ,0.01826 + ,155.358 + ,227.383 + ,0.0031 + ,0.00002 + ,0.00176 + ,0.01661 + ,162.568 + ,198.346 + ,0.00502 + ,0.00003 + ,0.00253 + ,0.01799 + ,197.076 + ,206.896 + ,0.00289 + ,0.00001 + ,0.00168 + ,0.00802 + ,199.228 + ,209.512 + ,0.00241 + ,0.00001 + ,0.00138 + ,0.00762 + ,198.383 + ,215.203 + ,0.00212 + ,0.00001 + ,0.00135 + ,0.00951 + ,202.266 + ,211.604 + ,0.0018 + ,0.000009 + ,0.00107 + ,0.00719 + ,203.184 + ,211.526 + ,0.00178 + ,0.000009 + ,0.00106 + ,0.00726 + ,201.464 + ,210.565 + ,0.00198 + ,0.00001 + ,0.00115 + ,0.00957 + ,177.876 + ,192.921 + ,0.00411 + ,0.00002 + ,0.00241 + ,0.01612 + ,176.17 + ,185.604 + ,0.00369 + ,0.00002 + ,0.00218 + ,0.01491 + ,180.198 + ,201.249 + ,0.00284 + ,0.00002 + ,0.00166 + ,0.0119 + ,187.733 + ,202.324 + ,0.00316 + ,0.00002 + ,0.00182 + ,0.01366 + ,186.163 + ,197.724 + ,0.00298 + ,0.00002 + ,0.00175 + ,0.01233 + ,184.055 + ,196.537 + ,0.00258 + ,0.00001 + ,0.00147 + ,0.01234 + ,237.226 + ,247.326 + ,0.00298 + ,0.00001 + ,0.00182 + ,0.01133 + ,241.404 + ,248.834 + ,0.00281 + ,0.00001 + ,0.00173 + ,0.01251 + ,243.439 + ,250.912 + ,0.0021 + ,0.000009 + ,0.00137 + ,0.01033 + ,242.852 + ,255.034 + ,0.00225 + ,0.000009 + ,0.00139 + ,0.01014 + ,245.51 + ,262.09 + ,0.00235 + ,0.00001 + ,0.00148 + ,0.01149 + ,252.455 + ,261.487 + ,0.00185 + ,0.000007 + ,0.00113 + ,0.0086 + ,122.188 + ,128.611 + ,0.00524 + ,0.00004 + ,0.00203 + ,0.01433 + ,122.964 + ,130.049 + ,0.00428 + ,0.00003 + ,0.00155 + ,0.014 + ,124.445 + ,135.069 + ,0.00431 + ,0.00003 + ,0.00167 + ,0.01685 + ,126.344 + ,134.231 + ,0.00448 + ,0.00004 + ,0.00169 + ,0.01614 + ,128.001 + ,138.052 + ,0.00436 + ,0.00003 + ,0.00166 + ,0.01677 + ,129.336 + ,139.867 + ,0.0049 + ,0.00004 + ,0.00183 + ,0.01947 + ,108.807 + ,134.656 + ,0.00761 + ,0.00007 + ,0.00486 + ,0.02067 + ,109.86 + ,126.358 + ,0.00874 + ,0.00008 + ,0.00539 + ,0.02454 + ,110.417 + ,131.067 + ,0.00784 + ,0.00007 + ,0.00514 + ,0.02802 + ,117.274 + ,129.916 + ,0.00752 + ,0.00006 + ,0.00469 + ,0.01948 + ,116.879 + ,131.897 + ,0.00788 + ,0.00007 + ,0.00493 + ,0.02137 + ,114.847 + ,271.314 + ,0.00867 + ,0.00008 + ,0.0052 + ,0.02519 + ,209.144 + ,237.494 + ,0.00282 + ,0.00001 + ,0.00152 + ,0.01382 + ,223.365 + ,238.987 + ,0.00264 + ,0.00001 + ,0.00151 + ,0.0134 + ,222.236 + ,231.345 + ,0.00266 + ,0.00001 + ,0.00144 + ,0.012 + ,228.832 + ,234.619 + ,0.00296 + ,0.00001 + ,0.00155 + ,0.01179 + ,229.401 + ,252.221 + ,0.00205 + ,0.000009 + ,0.00113 + ,0.01016 + ,228.969 + ,239.541 + ,0.00238 + ,0.00001 + ,0.0014 + ,0.01234 + ,140.341 + ,159.774 + ,0.00817 + ,0.00006 + ,0.0044 + ,0.02428 + ,136.969 + ,166.607 + ,0.00923 + ,0.00007 + ,0.00463 + ,0.02603 + ,143.533 + ,162.215 + ,0.01101 + ,0.00008 + ,0.00467 + ,0.03392 + ,148.09 + ,162.824 + ,0.00762 + ,0.00005 + ,0.00354 + ,0.03635 + ,142.729 + ,162.408 + ,0.00831 + ,0.00006 + ,0.00419 + ,0.02949 + ,136.358 + ,176.595 + ,0.00971 + ,0.00007 + ,0.00478 + ,0.03736 + ,120.08 + ,139.71 + ,0.00405 + ,0.00003 + ,0.0022 + ,0.01345 + ,112.014 + ,588.518 + ,0.00533 + ,0.00005 + ,0.00329 + ,0.01956 + ,110.793 + ,128.101 + ,0.00494 + ,0.00004 + ,0.00283 + ,0.01831 + ,110.707 + ,122.611 + ,0.00516 + ,0.00005 + ,0.00289 + ,0.01715 + ,112.876 + ,148.826 + ,0.005 + ,0.00004 + ,0.00289 + ,0.02704 + ,110.568 + ,125.394 + ,0.00462 + ,0.00004 + ,0.0028 + ,0.01636 + ,95.385 + ,102.145 + ,0.00608 + ,0.00006 + ,0.00332 + ,0.02455 + ,100.77 + ,115.697 + ,0.01038 + ,0.0001 + ,0.00576 + ,0.02139 + ,96.106 + ,108.664 + ,0.00694 + ,0.00007 + ,0.00415 + ,0.02876 + ,95.605 + ,107.715 + ,0.00702 + ,0.00007 + ,0.00371 + ,0.0219 + ,100.96 + ,110.019 + ,0.00606 + ,0.00006 + ,0.00348 + ,0.01751 + ,98.804 + ,102.305 + ,0.00432 + ,0.00004 + ,0.00258 + ,0.01552 + ,176.858 + ,205.56 + ,0.00747 + ,0.00004 + ,0.0042 + ,0.0351 + ,180.978 + ,200.125 + ,0.00406 + ,0.00002 + ,0.00244 + ,0.02877 + ,178.222 + ,202.45 + ,0.00321 + ,0.00002 + ,0.00194 + ,0.02784 + ,176.281 + ,227.381 + ,0.0052 + ,0.00003 + ,0.00312 + ,0.04683 + ,173.898 + ,211.35 + ,0.00448 + ,0.00003 + ,0.00254 + ,0.04802 + ,179.711 + ,225.93 + ,0.00709 + ,0.00004 + ,0.00419 + ,0.03455 + ,166.605 + ,206.008 + ,0.00742 + ,0.00004 + ,0.00453 + ,0.05114 + ,151.955 + ,163.335 + ,0.00419 + ,0.00003 + ,0.00227 + ,0.0569 + ,148.272 + ,164.989 + ,0.00459 + ,0.00003 + ,0.00256 + ,0.03051 + ,152.125 + ,161.469 + ,0.00382 + ,0.00003 + ,0.00226 + ,0.04398 + ,157.821 + ,172.975 + ,0.00358 + ,0.00002 + ,0.00196 + ,0.02764 + ,157.447 + ,163.267 + ,0.00369 + ,0.00002 + ,0.00197 + ,0.02571 + ,159.116 + ,168.913 + ,0.00342 + ,0.00002 + ,0.00184 + ,0.02809 + ,125.036 + ,143.946 + ,0.0128 + ,0.0001 + ,0.00623 + ,0.03088 + ,125.791 + ,140.557 + ,0.01378 + ,0.00011 + ,0.00655 + ,0.03908 + ,126.512 + ,141.756 + ,0.01936 + ,0.00015 + ,0.0099 + ,0.05783 + ,125.641 + ,141.068 + ,0.03316 + ,0.00026 + ,0.01522 + ,0.06196 + ,128.451 + ,150.449 + ,0.01551 + ,0.00012 + ,0.00909 + ,0.05174 + ,139.224 + ,586.567 + ,0.03011 + ,0.00022 + ,0.01628 + ,0.06023 + ,150.258 + ,154.609 + ,0.00248 + ,0.00002 + ,0.00136 + ,0.01009 + ,154.003 + ,160.267 + ,0.00183 + ,0.00001 + ,0.001 + ,0.00871 + ,149.689 + ,160.368 + ,0.00257 + ,0.00002 + ,0.00134 + ,0.01059 + ,155.078 + ,163.736 + ,0.00168 + ,0.00001 + ,0.00092 + ,0.00928 + ,151.884 + ,157.765 + ,0.00258 + ,0.00002 + ,0.00122 + ,0.01267 + ,151.989 + ,157.339 + ,0.00174 + ,0.00001 + ,0.00096 + ,0.00993 + ,193.03 + ,208.9 + ,0.00766 + ,0.00004 + ,0.00389 + ,0.02084 + ,200.714 + ,223.982 + ,0.00621 + ,0.00003 + ,0.00337 + ,0.01852 + ,208.519 + ,220.315 + ,0.00609 + ,0.00003 + ,0.00339 + ,0.01307 + ,204.664 + ,221.3 + ,0.00841 + ,0.00004 + ,0.00485 + ,0.01767 + ,210.141 + ,232.706 + ,0.00534 + ,0.00003 + ,0.0028 + ,0.01301 + ,206.327 + ,226.355 + ,0.00495 + ,0.00002 + ,0.00246 + ,0.01604 + ,151.872 + ,492.892 + ,0.00856 + ,0.00006 + ,0.00385 + ,0.01271 + ,158.219 + ,442.557 + ,0.00476 + ,0.00003 + ,0.00207 + ,0.01312 + ,170.756 + ,450.247 + ,0.00555 + ,0.00003 + ,0.00261 + ,0.01652 + ,178.285 + ,442.824 + ,0.00462 + ,0.00003 + ,0.00194 + ,0.01151 + ,217.116 + ,233.481 + ,0.00404 + ,0.00002 + ,0.00128 + ,0.01075 + ,128.94 + ,479.697 + ,0.00581 + ,0.00005 + ,0.00314 + ,0.01734 + ,176.824 + ,215.293 + ,0.0046 + ,0.00003 + ,0.00221 + ,0.01104 + ,138.19 + ,203.522 + ,0.00704 + ,0.00005 + ,0.00398 + ,0.0322 + ,182.018 + ,197.173 + ,0.00842 + ,0.00005 + ,0.00449 + ,0.01931 + ,156.239 + ,195.107 + ,0.00694 + ,0.00004 + ,0.00395 + ,0.0172 + ,145.174 + ,198.109 + ,0.00733 + ,0.00005 + ,0.00422 + ,0.01944 + ,138.145 + ,197.238 + ,0.00544 + ,0.00004 + ,0.00327 + ,0.02259 + ,166.888 + ,198.966 + ,0.00638 + ,0.00004 + ,0.00351 + ,0.02301 + ,119.031 + ,127.533 + ,0.0044 + ,0.00004 + ,0.00192 + ,0.00811 + ,120.078 + ,126.632 + ,0.0027 + ,0.00002 + ,0.00135 + ,0.00903 + ,120.289 + ,128.143 + ,0.00492 + ,0.00004 + ,0.00238 + ,0.01194 + ,120.256 + ,125.306 + ,0.00407 + ,0.00003 + ,0.00205 + ,0.0131 + ,119.056 + ,125.213 + ,0.00346 + ,0.00003 + ,0.0017 + ,0.00915 + ,118.747 + ,123.723 + ,0.00331 + ,0.00003 + ,0.00171 + ,0.00903 + ,106.516 + ,112.777 + ,0.00589 + ,0.00006 + ,0.00319 + ,0.03651 + ,110.453 + ,127.611 + ,0.00494 + ,0.00004 + ,0.00315 + ,0.03316 + ,113.4 + ,133.344 + ,0.00451 + ,0.00004 + ,0.00283 + ,0.0437 + ,113.166 + ,130.27 + ,0.00502 + ,0.00004 + ,0.00312 + ,0.04134 + ,112.239 + ,126.609 + ,0.00472 + ,0.00004 + ,0.0029 + ,0.04451 + ,116.15 + ,131.731 + ,0.00381 + ,0.00003 + ,0.00232 + ,0.0277 + ,170.368 + ,268.796 + ,0.00571 + ,0.00003 + ,0.00269 + ,0.02824 + ,208.083 + ,253.792 + ,0.00757 + ,0.00004 + ,0.00428 + ,0.04464 + ,198.458 + ,219.29 + ,0.00376 + ,0.00002 + ,0.00215 + ,0.0253 + ,202.805 + ,231.508 + ,0.0037 + ,0.00002 + ,0.00211 + ,0.01506 + ,202.544 + ,241.35 + ,0.00254 + ,0.00001 + ,0.00133 + ,0.02006 + ,223.361 + ,263.872 + ,0.00352 + ,0.00002 + ,0.00188 + ,0.01909 + ,169.774 + ,191.759 + ,0.01568 + ,0.00009 + ,0.00946 + ,0.08808 + ,183.52 + ,216.814 + ,0.01466 + ,0.00008 + ,0.00819 + ,0.06359 + ,188.62 + ,216.302 + ,0.01719 + ,0.00009 + ,0.01027 + ,0.06824 + ,202.632 + ,565.74 + ,0.01627 + ,0.00008 + ,0.00963 + ,0.0646 + ,186.695 + ,211.961 + ,0.01872 + ,0.0001 + ,0.01154 + ,0.06259 + ,192.818 + ,224.429 + ,0.03107 + ,0.00016 + ,0.01958 + ,0.13778 + ,198.116 + ,233.099 + ,0.02714 + ,0.00014 + ,0.01699 + ,0.08318 + ,121.345 + ,139.644 + ,0.00684 + ,0.00006 + ,0.00332 + ,0.02056 + ,119.1 + ,128.442 + ,0.00692 + ,0.00006 + ,0.003 + ,0.02018 + ,117.87 + ,127.349 + ,0.00647 + ,0.00005 + ,0.003 + ,0.02402 + ,122.336 + ,142.369 + ,0.00727 + ,0.00006 + ,0.00339 + ,0.01771 + ,117.963 + ,134.209 + ,0.01813 + ,0.00015 + ,0.00718 + ,0.02916 + ,126.144 + ,154.284 + ,0.00975 + ,0.00008 + ,0.00454 + ,0.02157 + ,127.93 + ,138.752 + ,0.00605 + ,0.00005 + ,0.00318 + ,0.03105 + ,114.238 + ,124.393 + ,0.00581 + ,0.00005 + ,0.00316 + ,0.04114 + ,115.322 + ,135.738 + ,0.00619 + ,0.00005 + ,0.00329 + ,0.02931 + ,114.554 + ,126.778 + ,0.00651 + ,0.00006 + ,0.0034 + ,0.03091 + ,112.15 + ,131.669 + ,0.00519 + ,0.00005 + ,0.00284 + ,0.01363 + ,102.273 + ,142.83 + ,0.00907 + ,0.00009 + ,0.00461 + ,0.02073 + ,236.2 + ,244.663 + ,0.00277 + ,0.00001 + ,0.00153 + ,0.01621 + ,237.323 + ,243.709 + ,0.00303 + ,0.00001 + ,0.00159 + ,0.00882 + ,260.105 + ,264.919 + ,0.00339 + ,0.00001 + ,0.00186 + ,0.01367 + ,197.569 + ,217.627 + ,0.00803 + ,0.00004 + ,0.00448 + ,0.01439 + ,240.301 + ,245.135 + ,0.00517 + ,0.00002 + ,0.00283 + ,0.01344 + ,244.99 + ,272.21 + ,0.00451 + ,0.00002 + ,0.00237 + ,0.01255 + ,112.547 + ,133.374 + ,0.00355 + ,0.00003 + ,0.0019 + ,0.0114 + ,110.739 + ,113.597 + ,0.00356 + ,0.00003 + ,0.002 + ,0.01285 + ,113.715 + ,116.443 + ,0.00349 + ,0.00003 + ,0.00203 + ,0.01148 + ,117.004 + ,144.466 + ,0.00353 + ,0.00003 + ,0.00218 + ,0.01318 + ,115.38 + ,123.109 + ,0.00332 + ,0.00003 + ,0.00199 + ,0.01133 + ,116.388 + ,129.038 + ,0.00346 + ,0.00003 + ,0.00213 + ,0.01331 + ,151.737 + ,190.204 + ,0.00314 + ,0.00002 + ,0.00162 + ,0.0123 + ,148.79 + ,158.359 + ,0.00309 + ,0.00002 + ,0.00186 + ,0.01309 + ,148.143 + ,155.982 + ,0.00392 + ,0.00003 + ,0.00231 + ,0.01263 + ,150.44 + ,163.441 + ,0.00396 + ,0.00003 + ,0.00233 + ,0.02148 + ,148.462 + ,161.078 + ,0.00397 + ,0.00003 + ,0.00235 + ,0.01559 + ,149.818 + ,163.417 + ,0.00336 + ,0.00002 + ,0.00198 + ,0.01666 + ,117.226 + ,123.925 + ,0.00417 + ,0.00004 + ,0.0027 + ,0.01949 + ,116.848 + ,217.552 + ,0.00531 + ,0.00005 + ,0.00346 + ,0.01756 + ,116.286 + ,177.291 + ,0.00314 + ,0.00003 + ,0.00192 + ,0.01691 + ,116.556 + ,592.03 + ,0.00496 + ,0.00004 + ,0.00263 + ,0.01491 + ,116.342 + ,581.289 + ,0.00267 + ,0.00002 + ,0.00148 + ,0.01144 + ,114.563 + ,119.167 + ,0.00327 + ,0.00003 + ,0.00184 + ,0.01095 + ,201.774 + ,262.707 + ,0.00694 + ,0.00003 + ,0.00396 + ,0.01758 + ,174.188 + ,230.978 + ,0.00459 + ,0.00003 + ,0.00259 + ,0.02745 + ,209.516 + ,253.017 + ,0.00564 + ,0.00003 + ,0.00292 + ,0.01879 + ,174.688 + ,240.005 + ,0.0136 + ,0.00008 + ,0.00564 + ,0.01667 + ,198.764 + ,396.961 + ,0.0074 + ,0.00004 + ,0.0039 + ,0.01588 + ,214.289 + ,260.277 + ,0.00567 + ,0.00003 + ,0.00317 + ,0.01373) + ,dim=c(6 + ,195) + ,dimnames=list(c('MDVP:Fo(Hz)' + ,'MDVP:Fhi(Hz)' + ,'MDVP:Jitter(%)' + ,'MDVP:Jitter(Abs)' + ,'MDVP:PPQ' + ,'MDVP:APQ') + ,1:195)) > y <- array(NA,dim=c(6,195),dimnames=list(c('MDVP:Fo(Hz)','MDVP:Fhi(Hz)','MDVP:Jitter(%)','MDVP:Jitter(Abs)','MDVP:PPQ','MDVP:APQ'),1:195)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > par3 = 'No Linear Trend' > par2 = 'Do not include Seasonal Dummies' > par1 = '1' > par3 <- 'No Linear Trend' > par2 <- 'Do not include Seasonal Dummies' > par1 <- '1' > #'GNU S' R Code compiled by R2WASP v. 1.2.327 () > #Author: root > #To cite this work: Wessa P., (2013), Multiple Regression (v1.0.29) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_multipleregression.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > # > library(lattice) > library(lmtest) Loading required package: zoo Attaching package: 'zoo' The following objects are masked from 'package:base': as.Date, as.Date.numeric > n25 <- 25 #minimum number of obs. for Goldfeld-Quandt test > par1 <- as.numeric(par1) > x <- t(y) > k <- length(x[1,]) > n <- length(x[,1]) > x1 <- cbind(x[,par1], x[,1:k!=par1]) > mycolnames <- c(colnames(x)[par1], colnames(x)[1:k!=par1]) > colnames(x1) <- mycolnames #colnames(x)[par1] > x <- x1 > if (par3 == 'First Differences'){ + x2 <- array(0, dim=c(n-1,k), dimnames=list(1:(n-1), paste('(1-B)',colnames(x),sep=''))) + for (i in 1:n-1) { + for (j in 1:k) { + x2[i,j] <- x[i+1,j] - x[i,j] + } + } + x <- x2 + } > if (par2 == 'Include Monthly Dummies'){ + x2 <- array(0, dim=c(n,11), dimnames=list(1:n, paste('M', seq(1:11), sep =''))) + for (i in 1:11){ + x2[seq(i,n,12),i] <- 1 + } + x <- cbind(x, x2) + } > if (par2 == 'Include Quarterly Dummies'){ + x2 <- array(0, dim=c(n,3), dimnames=list(1:n, paste('Q', seq(1:3), sep =''))) + for (i in 1:3){ + x2[seq(i,n,4),i] <- 1 + } + x <- cbind(x, x2) + } > k <- length(x[1,]) > if (par3 == 'Linear Trend'){ + x <- cbind(x, c(1:n)) + colnames(x)[k+1] <- 't' + } > x MDVP:Fo(Hz) MDVP:Fhi(Hz) MDVP:Jitter(%) MDVP:Jitter(Abs) MDVP:PPQ MDVP:APQ 1 119.992 157.302 0.00784 7.0e-05 0.00554 0.02971 2 122.400 148.650 0.00968 8.0e-05 0.00696 0.04368 3 116.682 131.111 0.01050 9.0e-05 0.00781 0.03590 4 116.676 137.871 0.00997 9.0e-05 0.00698 0.03772 5 116.014 141.781 0.01284 1.1e-04 0.00908 0.04465 6 120.552 131.162 0.00968 8.0e-05 0.00750 0.03243 7 120.267 137.244 0.00333 3.0e-05 0.00202 0.01351 8 107.332 113.840 0.00290 3.0e-05 0.00182 0.01256 9 95.730 132.068 0.00551 6.0e-05 0.00332 0.01717 10 95.056 120.103 0.00532 6.0e-05 0.00332 0.02444 11 88.333 112.240 0.00505 6.0e-05 0.00330 0.01892 12 91.904 115.871 0.00540 6.0e-05 0.00336 0.02214 13 136.926 159.866 0.00293 2.0e-05 0.00153 0.01140 14 139.173 179.139 0.00390 3.0e-05 0.00208 0.01797 15 152.845 163.305 0.00294 2.0e-05 0.00149 0.01246 16 142.167 217.455 0.00369 3.0e-05 0.00203 0.01359 17 144.188 349.259 0.00544 4.0e-05 0.00292 0.02074 18 168.778 232.181 0.00718 4.0e-05 0.00387 0.03430 19 153.046 175.829 0.00742 5.0e-05 0.00432 0.05767 20 156.405 189.398 0.00768 5.0e-05 0.00399 0.04310 21 153.848 165.738 0.00840 5.0e-05 0.00450 0.04055 22 153.880 172.860 0.00480 3.0e-05 0.00267 0.04525 23 167.930 193.221 0.00442 3.0e-05 0.00247 0.04246 24 173.917 192.735 0.00476 3.0e-05 0.00258 0.03772 25 163.656 200.841 0.00742 5.0e-05 0.00390 0.01497 26 104.400 206.002 0.00633 6.0e-05 0.00375 0.03780 27 171.041 208.313 0.00455 3.0e-05 0.00234 0.01872 28 146.845 208.701 0.00496 3.0e-05 0.00275 0.01826 29 155.358 227.383 0.00310 2.0e-05 0.00176 0.01661 30 162.568 198.346 0.00502 3.0e-05 0.00253 0.01799 31 197.076 206.896 0.00289 1.0e-05 0.00168 0.00802 32 199.228 209.512 0.00241 1.0e-05 0.00138 0.00762 33 198.383 215.203 0.00212 1.0e-05 0.00135 0.00951 34 202.266 211.604 0.00180 9.0e-06 0.00107 0.00719 35 203.184 211.526 0.00178 9.0e-06 0.00106 0.00726 36 201.464 210.565 0.00198 1.0e-05 0.00115 0.00957 37 177.876 192.921 0.00411 2.0e-05 0.00241 0.01612 38 176.170 185.604 0.00369 2.0e-05 0.00218 0.01491 39 180.198 201.249 0.00284 2.0e-05 0.00166 0.01190 40 187.733 202.324 0.00316 2.0e-05 0.00182 0.01366 41 186.163 197.724 0.00298 2.0e-05 0.00175 0.01233 42 184.055 196.537 0.00258 1.0e-05 0.00147 0.01234 43 237.226 247.326 0.00298 1.0e-05 0.00182 0.01133 44 241.404 248.834 0.00281 1.0e-05 0.00173 0.01251 45 243.439 250.912 0.00210 9.0e-06 0.00137 0.01033 46 242.852 255.034 0.00225 9.0e-06 0.00139 0.01014 47 245.510 262.090 0.00235 1.0e-05 0.00148 0.01149 48 252.455 261.487 0.00185 7.0e-06 0.00113 0.00860 49 122.188 128.611 0.00524 4.0e-05 0.00203 0.01433 50 122.964 130.049 0.00428 3.0e-05 0.00155 0.01400 51 124.445 135.069 0.00431 3.0e-05 0.00167 0.01685 52 126.344 134.231 0.00448 4.0e-05 0.00169 0.01614 53 128.001 138.052 0.00436 3.0e-05 0.00166 0.01677 54 129.336 139.867 0.00490 4.0e-05 0.00183 0.01947 55 108.807 134.656 0.00761 7.0e-05 0.00486 0.02067 56 109.860 126.358 0.00874 8.0e-05 0.00539 0.02454 57 110.417 131.067 0.00784 7.0e-05 0.00514 0.02802 58 117.274 129.916 0.00752 6.0e-05 0.00469 0.01948 59 116.879 131.897 0.00788 7.0e-05 0.00493 0.02137 60 114.847 271.314 0.00867 8.0e-05 0.00520 0.02519 61 209.144 237.494 0.00282 1.0e-05 0.00152 0.01382 62 223.365 238.987 0.00264 1.0e-05 0.00151 0.01340 63 222.236 231.345 0.00266 1.0e-05 0.00144 0.01200 64 228.832 234.619 0.00296 1.0e-05 0.00155 0.01179 65 229.401 252.221 0.00205 9.0e-06 0.00113 0.01016 66 228.969 239.541 0.00238 1.0e-05 0.00140 0.01234 67 140.341 159.774 0.00817 6.0e-05 0.00440 0.02428 68 136.969 166.607 0.00923 7.0e-05 0.00463 0.02603 69 143.533 162.215 0.01101 8.0e-05 0.00467 0.03392 70 148.090 162.824 0.00762 5.0e-05 0.00354 0.03635 71 142.729 162.408 0.00831 6.0e-05 0.00419 0.02949 72 136.358 176.595 0.00971 7.0e-05 0.00478 0.03736 73 120.080 139.710 0.00405 3.0e-05 0.00220 0.01345 74 112.014 588.518 0.00533 5.0e-05 0.00329 0.01956 75 110.793 128.101 0.00494 4.0e-05 0.00283 0.01831 76 110.707 122.611 0.00516 5.0e-05 0.00289 0.01715 77 112.876 148.826 0.00500 4.0e-05 0.00289 0.02704 78 110.568 125.394 0.00462 4.0e-05 0.00280 0.01636 79 95.385 102.145 0.00608 6.0e-05 0.00332 0.02455 80 100.770 115.697 0.01038 1.0e-04 0.00576 0.02139 81 96.106 108.664 0.00694 7.0e-05 0.00415 0.02876 82 95.605 107.715 0.00702 7.0e-05 0.00371 0.02190 83 100.960 110.019 0.00606 6.0e-05 0.00348 0.01751 84 98.804 102.305 0.00432 4.0e-05 0.00258 0.01552 85 176.858 205.560 0.00747 4.0e-05 0.00420 0.03510 86 180.978 200.125 0.00406 2.0e-05 0.00244 0.02877 87 178.222 202.450 0.00321 2.0e-05 0.00194 0.02784 88 176.281 227.381 0.00520 3.0e-05 0.00312 0.04683 89 173.898 211.350 0.00448 3.0e-05 0.00254 0.04802 90 179.711 225.930 0.00709 4.0e-05 0.00419 0.03455 91 166.605 206.008 0.00742 4.0e-05 0.00453 0.05114 92 151.955 163.335 0.00419 3.0e-05 0.00227 0.05690 93 148.272 164.989 0.00459 3.0e-05 0.00256 0.03051 94 152.125 161.469 0.00382 3.0e-05 0.00226 0.04398 95 157.821 172.975 0.00358 2.0e-05 0.00196 0.02764 96 157.447 163.267 0.00369 2.0e-05 0.00197 0.02571 97 159.116 168.913 0.00342 2.0e-05 0.00184 0.02809 98 125.036 143.946 0.01280 1.0e-04 0.00623 0.03088 99 125.791 140.557 0.01378 1.1e-04 0.00655 0.03908 100 126.512 141.756 0.01936 1.5e-04 0.00990 0.05783 101 125.641 141.068 0.03316 2.6e-04 0.01522 0.06196 102 128.451 150.449 0.01551 1.2e-04 0.00909 0.05174 103 139.224 586.567 0.03011 2.2e-04 0.01628 0.06023 104 150.258 154.609 0.00248 2.0e-05 0.00136 0.01009 105 154.003 160.267 0.00183 1.0e-05 0.00100 0.00871 106 149.689 160.368 0.00257 2.0e-05 0.00134 0.01059 107 155.078 163.736 0.00168 1.0e-05 0.00092 0.00928 108 151.884 157.765 0.00258 2.0e-05 0.00122 0.01267 109 151.989 157.339 0.00174 1.0e-05 0.00096 0.00993 110 193.030 208.900 0.00766 4.0e-05 0.00389 0.02084 111 200.714 223.982 0.00621 3.0e-05 0.00337 0.01852 112 208.519 220.315 0.00609 3.0e-05 0.00339 0.01307 113 204.664 221.300 0.00841 4.0e-05 0.00485 0.01767 114 210.141 232.706 0.00534 3.0e-05 0.00280 0.01301 115 206.327 226.355 0.00495 2.0e-05 0.00246 0.01604 116 151.872 492.892 0.00856 6.0e-05 0.00385 0.01271 117 158.219 442.557 0.00476 3.0e-05 0.00207 0.01312 118 170.756 450.247 0.00555 3.0e-05 0.00261 0.01652 119 178.285 442.824 0.00462 3.0e-05 0.00194 0.01151 120 217.116 233.481 0.00404 2.0e-05 0.00128 0.01075 121 128.940 479.697 0.00581 5.0e-05 0.00314 0.01734 122 176.824 215.293 0.00460 3.0e-05 0.00221 0.01104 123 138.190 203.522 0.00704 5.0e-05 0.00398 0.03220 124 182.018 197.173 0.00842 5.0e-05 0.00449 0.01931 125 156.239 195.107 0.00694 4.0e-05 0.00395 0.01720 126 145.174 198.109 0.00733 5.0e-05 0.00422 0.01944 127 138.145 197.238 0.00544 4.0e-05 0.00327 0.02259 128 166.888 198.966 0.00638 4.0e-05 0.00351 0.02301 129 119.031 127.533 0.00440 4.0e-05 0.00192 0.00811 130 120.078 126.632 0.00270 2.0e-05 0.00135 0.00903 131 120.289 128.143 0.00492 4.0e-05 0.00238 0.01194 132 120.256 125.306 0.00407 3.0e-05 0.00205 0.01310 133 119.056 125.213 0.00346 3.0e-05 0.00170 0.00915 134 118.747 123.723 0.00331 3.0e-05 0.00171 0.00903 135 106.516 112.777 0.00589 6.0e-05 0.00319 0.03651 136 110.453 127.611 0.00494 4.0e-05 0.00315 0.03316 137 113.400 133.344 0.00451 4.0e-05 0.00283 0.04370 138 113.166 130.270 0.00502 4.0e-05 0.00312 0.04134 139 112.239 126.609 0.00472 4.0e-05 0.00290 0.04451 140 116.150 131.731 0.00381 3.0e-05 0.00232 0.02770 141 170.368 268.796 0.00571 3.0e-05 0.00269 0.02824 142 208.083 253.792 0.00757 4.0e-05 0.00428 0.04464 143 198.458 219.290 0.00376 2.0e-05 0.00215 0.02530 144 202.805 231.508 0.00370 2.0e-05 0.00211 0.01506 145 202.544 241.350 0.00254 1.0e-05 0.00133 0.02006 146 223.361 263.872 0.00352 2.0e-05 0.00188 0.01909 147 169.774 191.759 0.01568 9.0e-05 0.00946 0.08808 148 183.520 216.814 0.01466 8.0e-05 0.00819 0.06359 149 188.620 216.302 0.01719 9.0e-05 0.01027 0.06824 150 202.632 565.740 0.01627 8.0e-05 0.00963 0.06460 151 186.695 211.961 0.01872 1.0e-04 0.01154 0.06259 152 192.818 224.429 0.03107 1.6e-04 0.01958 0.13778 153 198.116 233.099 0.02714 1.4e-04 0.01699 0.08318 154 121.345 139.644 0.00684 6.0e-05 0.00332 0.02056 155 119.100 128.442 0.00692 6.0e-05 0.00300 0.02018 156 117.870 127.349 0.00647 5.0e-05 0.00300 0.02402 157 122.336 142.369 0.00727 6.0e-05 0.00339 0.01771 158 117.963 134.209 0.01813 1.5e-04 0.00718 0.02916 159 126.144 154.284 0.00975 8.0e-05 0.00454 0.02157 160 127.930 138.752 0.00605 5.0e-05 0.00318 0.03105 161 114.238 124.393 0.00581 5.0e-05 0.00316 0.04114 162 115.322 135.738 0.00619 5.0e-05 0.00329 0.02931 163 114.554 126.778 0.00651 6.0e-05 0.00340 0.03091 164 112.150 131.669 0.00519 5.0e-05 0.00284 0.01363 165 102.273 142.830 0.00907 9.0e-05 0.00461 0.02073 166 236.200 244.663 0.00277 1.0e-05 0.00153 0.01621 167 237.323 243.709 0.00303 1.0e-05 0.00159 0.00882 168 260.105 264.919 0.00339 1.0e-05 0.00186 0.01367 169 197.569 217.627 0.00803 4.0e-05 0.00448 0.01439 170 240.301 245.135 0.00517 2.0e-05 0.00283 0.01344 171 244.990 272.210 0.00451 2.0e-05 0.00237 0.01255 172 112.547 133.374 0.00355 3.0e-05 0.00190 0.01140 173 110.739 113.597 0.00356 3.0e-05 0.00200 0.01285 174 113.715 116.443 0.00349 3.0e-05 0.00203 0.01148 175 117.004 144.466 0.00353 3.0e-05 0.00218 0.01318 176 115.380 123.109 0.00332 3.0e-05 0.00199 0.01133 177 116.388 129.038 0.00346 3.0e-05 0.00213 0.01331 178 151.737 190.204 0.00314 2.0e-05 0.00162 0.01230 179 148.790 158.359 0.00309 2.0e-05 0.00186 0.01309 180 148.143 155.982 0.00392 3.0e-05 0.00231 0.01263 181 150.440 163.441 0.00396 3.0e-05 0.00233 0.02148 182 148.462 161.078 0.00397 3.0e-05 0.00235 0.01559 183 149.818 163.417 0.00336 2.0e-05 0.00198 0.01666 184 117.226 123.925 0.00417 4.0e-05 0.00270 0.01949 185 116.848 217.552 0.00531 5.0e-05 0.00346 0.01756 186 116.286 177.291 0.00314 3.0e-05 0.00192 0.01691 187 116.556 592.030 0.00496 4.0e-05 0.00263 0.01491 188 116.342 581.289 0.00267 2.0e-05 0.00148 0.01144 189 114.563 119.167 0.00327 3.0e-05 0.00184 0.01095 190 201.774 262.707 0.00694 3.0e-05 0.00396 0.01758 191 174.188 230.978 0.00459 3.0e-05 0.00259 0.02745 192 209.516 253.017 0.00564 3.0e-05 0.00292 0.01879 193 174.688 240.005 0.01360 8.0e-05 0.00564 0.01667 194 198.764 396.961 0.00740 4.0e-05 0.00390 0.01588 195 214.289 260.277 0.00567 3.0e-05 0.00317 0.01373 > k <- length(x[1,]) > df <- as.data.frame(x) > (mylm <- lm(df)) Call: lm(formula = df) Coefficients: (Intercept) `MDVP:Fhi(Hz)` `MDVP:Jitter(%)` `MDVP:Jitter(Abs)` 1.602e+02 5.493e-02 1.984e+04 -2.614e+06 `MDVP:PPQ` `MDVP:APQ` -3.404e+03 -5.641e+02 > (mysum <- summary(mylm)) Call: lm(formula = df) Residuals: Min 1Q Median 3Q Max -65.010 -16.081 -3.418 16.635 68.162 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 1.602e+02 5.425e+00 29.538 < 2e-16 *** `MDVP:Fhi(Hz)` 5.493e-02 2.126e-02 2.584 0.01053 * `MDVP:Jitter(%)` 1.984e+04 2.130e+03 9.311 < 2e-16 *** `MDVP:Jitter(Abs)` -2.614e+06 1.626e+05 -16.073 < 2e-16 *** `MDVP:PPQ` -3.404e+03 3.168e+03 -1.075 0.28397 `MDVP:APQ` -5.641e+02 1.859e+02 -3.034 0.00275 ** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 Residual standard error: 24.52 on 189 degrees of freedom Multiple R-squared: 0.658, Adjusted R-squared: 0.6489 F-statistic: 72.72 on 5 and 189 DF, p-value: < 2.2e-16 > if (n > n25) { + kp3 <- k + 3 + nmkm3 <- n - k - 3 + gqarr <- array(NA, dim=c(nmkm3-kp3+1,3)) + numgqtests <- 0 + numsignificant1 <- 0 + numsignificant5 <- 0 + numsignificant10 <- 0 + for (mypoint in kp3:nmkm3) { + j <- 0 + numgqtests <- numgqtests + 1 + for (myalt in c('greater', 'two.sided', 'less')) { + j <- j + 1 + gqarr[mypoint-kp3+1,j] <- gqtest(mylm, point=mypoint, alternative=myalt)$p.value + } + if (gqarr[mypoint-kp3+1,2] < 0.01) numsignificant1 <- numsignificant1 + 1 + if (gqarr[mypoint-kp3+1,2] < 0.05) numsignificant5 <- numsignificant5 + 1 + if (gqarr[mypoint-kp3+1,2] < 0.10) numsignificant10 <- numsignificant10 + 1 + } + gqarr + } [,1] [,2] [,3] [1,] 7.742618e-03 1.548524e-02 0.992257382 [2,] 1.133007e-03 2.266014e-03 0.998866993 [3,] 1.554571e-04 3.109141e-04 0.999844543 [4,] 2.224004e-05 4.448009e-05 0.999977760 [5,] 3.147293e-06 6.294586e-06 0.999996853 [6,] 3.736279e-07 7.472558e-07 0.999999626 [7,] 1.011614e-05 2.023229e-05 0.999989884 [8,] 2.383327e-06 4.766655e-06 0.999997617 [9,] 6.021025e-06 1.204205e-05 0.999993979 [10,] 3.727243e-06 7.454485e-06 0.999996273 [11,] 9.480800e-07 1.896160e-06 0.999999052 [12,] 2.348330e-07 4.696660e-07 0.999999765 [13,] 2.704085e-07 5.408171e-07 0.999999730 [14,] 6.811517e-08 1.362303e-07 0.999999932 [15,] 2.733069e-07 5.466138e-07 0.999999727 [16,] 6.953092e-07 1.390618e-06 0.999999305 [17,] 2.417786e-06 4.835573e-06 0.999997582 [18,] 2.222969e-06 4.445938e-06 0.999997777 [19,] 4.896584e-06 9.793169e-06 0.999995103 [20,] 3.667619e-06 7.335238e-06 0.999996332 [21,] 1.464885e-06 2.929771e-06 0.999998535 [22,] 6.121011e-07 1.224202e-06 0.999999388 [23,] 2.253686e-06 4.507372e-06 0.999997746 [24,] 1.165909e-05 2.331818e-05 0.999988341 [25,] 2.843617e-05 5.687234e-05 0.999971564 [26,] 9.026566e-05 1.805313e-04 0.999909734 [27,] 1.781693e-04 3.563385e-04 0.999821831 [28,] 2.257628e-04 4.515257e-04 0.999774237 [29,] 1.347142e-04 2.694284e-04 0.999865286 [30,] 7.181644e-05 1.436329e-04 0.999928184 [31,] 5.688418e-05 1.137684e-04 0.999943116 [32,] 5.084805e-05 1.016961e-04 0.999949152 [33,] 4.656456e-05 9.312913e-05 0.999953435 [34,] 2.621021e-05 5.242041e-05 0.999973790 [35,] 7.564868e-05 1.512974e-04 0.999924351 [36,] 2.710198e-04 5.420396e-04 0.999728980 [37,] 1.390269e-03 2.780537e-03 0.998609731 [38,] 3.727365e-03 7.454730e-03 0.996272635 [39,] 9.025036e-03 1.805007e-02 0.990974964 [40,] 2.754101e-02 5.508202e-02 0.972458988 [41,] 3.126587e-02 6.253175e-02 0.968734126 [42,] 2.841380e-02 5.682761e-02 0.971586197 [43,] 2.540999e-02 5.081997e-02 0.974590014 [44,] 3.054359e-02 6.108718e-02 0.969456412 [45,] 2.757052e-02 5.514103e-02 0.972429484 [46,] 2.976922e-02 5.953843e-02 0.970230784 [47,] 2.381232e-02 4.762464e-02 0.976187678 [48,] 2.689654e-02 5.379309e-02 0.973103456 [49,] 2.151445e-02 4.302890e-02 0.978485551 [50,] 1.664632e-02 3.329265e-02 0.983353676 [51,] 1.439634e-02 2.879268e-02 0.985603659 [52,] 1.223246e-02 2.446492e-02 0.987767539 [53,] 9.567530e-03 1.913506e-02 0.990432470 [54,] 1.025131e-02 2.050261e-02 0.989748693 [55,] 1.107461e-02 2.214921e-02 0.988925395 [56,] 1.270013e-02 2.540026e-02 0.987299870 [57,] 2.033875e-02 4.067751e-02 0.979661245 [58,] 3.155455e-02 6.310910e-02 0.968445450 [59,] 2.759391e-02 5.518781e-02 0.972406093 [60,] 3.293675e-02 6.587351e-02 0.967063246 [61,] 8.243488e-02 1.648698e-01 0.917565119 [62,] 7.282855e-02 1.456571e-01 0.927171454 [63,] 6.124937e-02 1.224987e-01 0.938750628 [64,] 5.219171e-02 1.043834e-01 0.947808288 [65,] 6.685741e-02 1.337148e-01 0.933142585 [66,] 3.506688e-01 7.013377e-01 0.649331154 [67,] 3.808737e-01 7.617475e-01 0.619126252 [68,] 3.404152e-01 6.808304e-01 0.659584778 [69,] 3.558338e-01 7.116675e-01 0.644166249 [70,] 3.594836e-01 7.189673e-01 0.640516351 [71,] 3.257554e-01 6.515107e-01 0.674244650 [72,] 4.623153e-01 9.246305e-01 0.537684747 [73,] 4.487820e-01 8.975639e-01 0.551218038 [74,] 4.252787e-01 8.505575e-01 0.574721264 [75,] 3.862140e-01 7.724280e-01 0.613786019 [76,] 4.033774e-01 8.067547e-01 0.596622646 [77,] 3.798273e-01 7.596546e-01 0.620172704 [78,] 3.474733e-01 6.949466e-01 0.652526712 [79,] 3.268039e-01 6.536078e-01 0.673196107 [80,] 2.969276e-01 5.938553e-01 0.703072353 [81,] 2.963850e-01 5.927700e-01 0.703614994 [82,] 2.708282e-01 5.416564e-01 0.729171786 [83,] 2.561149e-01 5.122298e-01 0.743885085 [84,] 2.350927e-01 4.701854e-01 0.764907318 [85,] 2.118279e-01 4.236559e-01 0.788172059 [86,] 1.978947e-01 3.957894e-01 0.802105282 [87,] 1.807944e-01 3.615888e-01 0.819205586 [88,] 1.676331e-01 3.352662e-01 0.832366904 [89,] 1.460347e-01 2.920694e-01 0.853965323 [90,] 1.515168e-01 3.030336e-01 0.848483197 [91,] 1.857616e-01 3.715233e-01 0.814238357 [92,] 2.461898e-01 4.923796e-01 0.753810218 [93,] 4.318362e-01 8.636723e-01 0.568163849 [94,] 4.884749e-01 9.769499e-01 0.511525067 [95,] 7.601861e-01 4.796278e-01 0.239813925 [96,] 7.270356e-01 5.459287e-01 0.272964364 [97,] 7.170496e-01 5.659007e-01 0.282950358 [98,] 6.830277e-01 6.339446e-01 0.316972284 [99,] 6.609441e-01 6.781118e-01 0.339055922 [100,] 6.236341e-01 7.527318e-01 0.376365904 [101,] 6.117006e-01 7.765987e-01 0.388299350 [102,] 5.819926e-01 8.360148e-01 0.418007423 [103,] 5.437597e-01 9.124805e-01 0.456240274 [104,] 5.134757e-01 9.730485e-01 0.486524262 [105,] 4.934614e-01 9.869228e-01 0.506538594 [106,] 5.059755e-01 9.880491e-01 0.494024545 [107,] 4.652890e-01 9.305780e-01 0.534711020 [108,] 4.837355e-01 9.674710e-01 0.516264507 [109,] 5.004150e-01 9.991700e-01 0.499584985 [110,] 5.291816e-01 9.416367e-01 0.470818373 [111,] 4.874224e-01 9.748447e-01 0.512577647 [112,] 4.739509e-01 9.479018e-01 0.526049076 [113,] 4.435686e-01 8.871372e-01 0.556431415 [114,] 4.041042e-01 8.082083e-01 0.595895829 [115,] 3.719478e-01 7.438955e-01 0.628052229 [116,] 3.385538e-01 6.771077e-01 0.661446172 [117,] 3.494634e-01 6.989268e-01 0.650536596 [118,] 3.255912e-01 6.511823e-01 0.674408841 [119,] 2.948665e-01 5.897329e-01 0.705133528 [120,] 2.600830e-01 5.201660e-01 0.739917024 [121,] 2.372059e-01 4.744118e-01 0.762794081 [122,] 3.021812e-01 6.043625e-01 0.697818767 [123,] 2.961978e-01 5.923955e-01 0.703802244 [124,] 3.497592e-01 6.995185e-01 0.650240768 [125,] 3.553327e-01 7.106654e-01 0.644667319 [126,] 3.464853e-01 6.929706e-01 0.653514684 [127,] 3.453211e-01 6.906422e-01 0.654678894 [128,] 3.262184e-01 6.524368e-01 0.673781620 [129,] 2.868477e-01 5.736954e-01 0.713152299 [130,] 2.638636e-01 5.277273e-01 0.736136367 [131,] 2.330117e-01 4.660234e-01 0.766988279 [132,] 2.420313e-01 4.840625e-01 0.757968738 [133,] 2.618366e-01 5.236731e-01 0.738163439 [134,] 2.413290e-01 4.826581e-01 0.758670960 [135,] 2.262571e-01 4.525143e-01 0.773742866 [136,] 2.221195e-01 4.442391e-01 0.777880471 [137,] 1.965454e-01 3.930908e-01 0.803454618 [138,] 3.076368e-01 6.152735e-01 0.692363238 [139,] 2.935069e-01 5.870138e-01 0.706493112 [140,] 2.745167e-01 5.490335e-01 0.725483251 [141,] 2.726293e-01 5.452586e-01 0.727370689 [142,] 2.937924e-01 5.875848e-01 0.706207612 [143,] 2.741548e-01 5.483095e-01 0.725845244 [144,] 2.684344e-01 5.368687e-01 0.731565631 [145,] 3.386082e-01 6.772164e-01 0.661391824 [146,] 2.955776e-01 5.911553e-01 0.704422374 [147,] 2.523804e-01 5.047608e-01 0.747619606 [148,] 2.590654e-01 5.181308e-01 0.740934587 [149,] 2.201303e-01 4.402605e-01 0.779869746 [150,] 2.714873e-01 5.429746e-01 0.728512676 [151,] 2.584180e-01 5.168360e-01 0.741582011 [152,] 2.152688e-01 4.305375e-01 0.784731232 [153,] 1.951606e-01 3.903213e-01 0.804839366 [154,] 1.993361e-01 3.986722e-01 0.800663901 [155,] 1.613170e-01 3.226341e-01 0.838682956 [156,] 1.427334e-01 2.854668e-01 0.857266586 [157,] 7.165243e-01 5.669513e-01 0.283475660 [158,] 7.377488e-01 5.245024e-01 0.262251210 [159,] 7.869703e-01 4.260594e-01 0.213029686 [160,] 9.061278e-01 1.877444e-01 0.093872190 [161,] 9.186145e-01 1.627710e-01 0.081385500 [162,] 9.114638e-01 1.770725e-01 0.088536245 [163,] 9.964767e-01 7.046574e-03 0.003523287 [164,] 9.941990e-01 1.160196e-02 0.005800979 [165,] 9.923105e-01 1.537907e-02 0.007689536 [166,] 9.880353e-01 2.392945e-02 0.011964724 [167,] 9.834442e-01 3.311160e-02 0.016555798 [168,] 9.726364e-01 5.472717e-02 0.027363585 [169,] 9.632779e-01 7.344429e-02 0.036722145 [170,] 9.401669e-01 1.196662e-01 0.059833120 [171,] 9.074477e-01 1.851045e-01 0.092552252 [172,] 8.653451e-01 2.693098e-01 0.134654899 [173,] 7.950623e-01 4.098754e-01 0.204937701 [174,] 7.079480e-01 5.841039e-01 0.292051953 [175,] 6.612064e-01 6.775872e-01 0.338793598 [176,] 5.407257e-01 9.185487e-01 0.459274341 [177,] 4.042073e-01 8.084145e-01 0.595792744 [178,] 2.767925e-01 5.535849e-01 0.723207529 > postscript(file="/var/fisher/rcomp/tmp/1o66a1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(x[,1], type='l', main='Actuals and Interpolation', ylab='value of Actuals and Interpolation (dots)', xlab='time or index') > points(x[,1]-mysum$resid) > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/29jgk1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(mysum$resid, type='b', pch=19, main='Residuals', ylab='value of Residuals', xlab='time or index') > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/3akny1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > hist(mysum$resid, main='Residual Histogram', xlab='values of Residuals') > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/4otza1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > densityplot(~mysum$resid,col='black',main='Residual Density Plot', xlab='values of Residuals') > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/59zdl1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > qqnorm(mysum$resid, main='Residual Normal Q-Q Plot') > qqline(mysum$resid) > grid() > dev.off() null device 1 > (myerror <- as.ts(mysum$resid)) Time Series: Start = 1 End = 195 Frequency = 1 1 2 3 4 5 6 14.19058595 19.42789024 23.05010272 31.38668939 36.91416924 14.03273231 7 8 9 10 11 12 -20.64367659 -24.98071397 -3.23684461 4.61594304 0.49852305 -1.05165302 13 14 15 16 17 18 -26.28819193 -12.62487029 -10.29467411 -10.21094960 -16.94154396 -9.55121796 19 20 21 22 23 24 13.90288529 2.01735770 -13.22375423 1.97194037 20.18634331 17.15675200 25 26 27 28 29 30 -2.37706238 -1.79189675 6.05591578 -25.15763494 -11.21486998 -10.95718707 31 32 33 34 35 36 4.53919379 14.82155055 20.38017451 25.93262455 27.25705834 25.84588168 37 38 39 40 41 42 -4.90128953 0.65992364 17.22050909 19.88663260 21.15112020 -0.04191455 43 44 45 46 47 48 43.02701463 50.85342367 61.78843778 57.96064916 61.92912528 68.16217727 49 50 51 52 53 54 -29.50038703 -37.71848396 -35.09214210 -10.71470391 -32.77091926 -14.00809700 55 56 57 58 59 60 1.39745269 10.61642187 3.74165027 -15.47679781 4.89862923 8.74975239 61 62 63 64 65 66 19.04203031 36.48041046 34.34645293 35.06804551 47.75741844 46.23876098 67 68 69 70 71 72 -5.22230468 -2.08806262 0.13405883 -8.98731387 -3.53190246 -5.86689998 73 74 75 76 77 78 -34.66860192 -33.34474463 -29.94845781 -8.40993393 -25.06523609 -24.87958145 79 80 81 82 83 84 -9.08140748 21.33850230 5.56024400 -1.84287511 -6.96869113 -30.64753473 85 86 87 88 89 90 -4.18659827 6.03456281 17.78415375 15.86727050 27.34305079 4.74064000 91 92 93 94 95 96 -3.30117988 17.87954749 -7.72737852 18.16907360 -8.38164295 -11.45892783 97 98 99 100 101 102 -3.84454717 3.00468388 16.35892106 32.86106429 66.24612247 26.08519158 103 104 105 106 107 108 13.94186698 -5.05923298 -16.87284008 -7.51576965 -12.96389783 -4.61134596 109 110 111 112 113 114 -16.38882444 -1.06586193 5.33519070 12.71566160 -3.50958196 26.49121565 115 116 117 118 119 120 5.17675856 -28.12295799 -27.87580234 -27.67492183 -6.39824464 26.62355533 121 122 123 124 125 126 -21.72532271 5.68906355 -10.46143656 0.80772466 -24.66690079 -15.31305861 127 128 129 130 131 132 -12.39948003 -1.34261420 -19.81963112 -38.69826048 -25.18312597 -34.80618357 133 134 135 136 137 138 -27.32115221 -24.60667424 11.53821187 -20.79558069 -4.77819757 -15.30336762 139 140 141 142 143 144 -9.03946754 -24.95319222 -14.38659446 28.05932520 25.46789223 24.42152346 145 146 147 148 149 150 20.65719992 48.26051830 5.11504536 -6.55766791 -15.77233049 -33.07423474 151 152 153 154 155 156 -20.53383714 -33.45739602 -42.57240401 -2.50659285 -7.02678713 -23.24162978 157 158 159 160 161 162 -11.56377226 23.69246392 0.76411276 -0.89891310 -3.41823379 -16.72534957 163 164 165 166 167 168 4.06532490 -10.21530162 16.91148303 48.07822170 40.13212711 58.26335639 169 170 171 172 173 174 -5.97516224 33.54837996 47.77355869 -34.11357174 -33.87529826 -30.33782568 175 176 177 178 179 180 -27.91189677 -25.88775641 -26.38889007 -16.49492348 -15.43839527 -5.00889072 181 182 183 184 185 186 1.14522380 -4.15570795 -17.62145709 -7.78986563 -8.28743139 -21.47817213 187 188 189 190 191 192 -52.66313328 -65.01020499 -26.22144104 -8.73339486 12.94006539 22.46891954 193 194 195 -30.78543929 -3.26815593 24.24485571 > postscript(file="/var/fisher/rcomp/tmp/6nnzf1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > dum <- cbind(lag(myerror,k=1),myerror) > dum Time Series: Start = 0 End = 195 Frequency = 1 lag(myerror, k = 1) myerror 0 14.19058595 NA 1 19.42789024 14.19058595 2 23.05010272 19.42789024 3 31.38668939 23.05010272 4 36.91416924 31.38668939 5 14.03273231 36.91416924 6 -20.64367659 14.03273231 7 -24.98071397 -20.64367659 8 -3.23684461 -24.98071397 9 4.61594304 -3.23684461 10 0.49852305 4.61594304 11 -1.05165302 0.49852305 12 -26.28819193 -1.05165302 13 -12.62487029 -26.28819193 14 -10.29467411 -12.62487029 15 -10.21094960 -10.29467411 16 -16.94154396 -10.21094960 17 -9.55121796 -16.94154396 18 13.90288529 -9.55121796 19 2.01735770 13.90288529 20 -13.22375423 2.01735770 21 1.97194037 -13.22375423 22 20.18634331 1.97194037 23 17.15675200 20.18634331 24 -2.37706238 17.15675200 25 -1.79189675 -2.37706238 26 6.05591578 -1.79189675 27 -25.15763494 6.05591578 28 -11.21486998 -25.15763494 29 -10.95718707 -11.21486998 30 4.53919379 -10.95718707 31 14.82155055 4.53919379 32 20.38017451 14.82155055 33 25.93262455 20.38017451 34 27.25705834 25.93262455 35 25.84588168 27.25705834 36 -4.90128953 25.84588168 37 0.65992364 -4.90128953 38 17.22050909 0.65992364 39 19.88663260 17.22050909 40 21.15112020 19.88663260 41 -0.04191455 21.15112020 42 43.02701463 -0.04191455 43 50.85342367 43.02701463 44 61.78843778 50.85342367 45 57.96064916 61.78843778 46 61.92912528 57.96064916 47 68.16217727 61.92912528 48 -29.50038703 68.16217727 49 -37.71848396 -29.50038703 50 -35.09214210 -37.71848396 51 -10.71470391 -35.09214210 52 -32.77091926 -10.71470391 53 -14.00809700 -32.77091926 54 1.39745269 -14.00809700 55 10.61642187 1.39745269 56 3.74165027 10.61642187 57 -15.47679781 3.74165027 58 4.89862923 -15.47679781 59 8.74975239 4.89862923 60 19.04203031 8.74975239 61 36.48041046 19.04203031 62 34.34645293 36.48041046 63 35.06804551 34.34645293 64 47.75741844 35.06804551 65 46.23876098 47.75741844 66 -5.22230468 46.23876098 67 -2.08806262 -5.22230468 68 0.13405883 -2.08806262 69 -8.98731387 0.13405883 70 -3.53190246 -8.98731387 71 -5.86689998 -3.53190246 72 -34.66860192 -5.86689998 73 -33.34474463 -34.66860192 74 -29.94845781 -33.34474463 75 -8.40993393 -29.94845781 76 -25.06523609 -8.40993393 77 -24.87958145 -25.06523609 78 -9.08140748 -24.87958145 79 21.33850230 -9.08140748 80 5.56024400 21.33850230 81 -1.84287511 5.56024400 82 -6.96869113 -1.84287511 83 -30.64753473 -6.96869113 84 -4.18659827 -30.64753473 85 6.03456281 -4.18659827 86 17.78415375 6.03456281 87 15.86727050 17.78415375 88 27.34305079 15.86727050 89 4.74064000 27.34305079 90 -3.30117988 4.74064000 91 17.87954749 -3.30117988 92 -7.72737852 17.87954749 93 18.16907360 -7.72737852 94 -8.38164295 18.16907360 95 -11.45892783 -8.38164295 96 -3.84454717 -11.45892783 97 3.00468388 -3.84454717 98 16.35892106 3.00468388 99 32.86106429 16.35892106 100 66.24612247 32.86106429 101 26.08519158 66.24612247 102 13.94186698 26.08519158 103 -5.05923298 13.94186698 104 -16.87284008 -5.05923298 105 -7.51576965 -16.87284008 106 -12.96389783 -7.51576965 107 -4.61134596 -12.96389783 108 -16.38882444 -4.61134596 109 -1.06586193 -16.38882444 110 5.33519070 -1.06586193 111 12.71566160 5.33519070 112 -3.50958196 12.71566160 113 26.49121565 -3.50958196 114 5.17675856 26.49121565 115 -28.12295799 5.17675856 116 -27.87580234 -28.12295799 117 -27.67492183 -27.87580234 118 -6.39824464 -27.67492183 119 26.62355533 -6.39824464 120 -21.72532271 26.62355533 121 5.68906355 -21.72532271 122 -10.46143656 5.68906355 123 0.80772466 -10.46143656 124 -24.66690079 0.80772466 125 -15.31305861 -24.66690079 126 -12.39948003 -15.31305861 127 -1.34261420 -12.39948003 128 -19.81963112 -1.34261420 129 -38.69826048 -19.81963112 130 -25.18312597 -38.69826048 131 -34.80618357 -25.18312597 132 -27.32115221 -34.80618357 133 -24.60667424 -27.32115221 134 11.53821187 -24.60667424 135 -20.79558069 11.53821187 136 -4.77819757 -20.79558069 137 -15.30336762 -4.77819757 138 -9.03946754 -15.30336762 139 -24.95319222 -9.03946754 140 -14.38659446 -24.95319222 141 28.05932520 -14.38659446 142 25.46789223 28.05932520 143 24.42152346 25.46789223 144 20.65719992 24.42152346 145 48.26051830 20.65719992 146 5.11504536 48.26051830 147 -6.55766791 5.11504536 148 -15.77233049 -6.55766791 149 -33.07423474 -15.77233049 150 -20.53383714 -33.07423474 151 -33.45739602 -20.53383714 152 -42.57240401 -33.45739602 153 -2.50659285 -42.57240401 154 -7.02678713 -2.50659285 155 -23.24162978 -7.02678713 156 -11.56377226 -23.24162978 157 23.69246392 -11.56377226 158 0.76411276 23.69246392 159 -0.89891310 0.76411276 160 -3.41823379 -0.89891310 161 -16.72534957 -3.41823379 162 4.06532490 -16.72534957 163 -10.21530162 4.06532490 164 16.91148303 -10.21530162 165 48.07822170 16.91148303 166 40.13212711 48.07822170 167 58.26335639 40.13212711 168 -5.97516224 58.26335639 169 33.54837996 -5.97516224 170 47.77355869 33.54837996 171 -34.11357174 47.77355869 172 -33.87529826 -34.11357174 173 -30.33782568 -33.87529826 174 -27.91189677 -30.33782568 175 -25.88775641 -27.91189677 176 -26.38889007 -25.88775641 177 -16.49492348 -26.38889007 178 -15.43839527 -16.49492348 179 -5.00889072 -15.43839527 180 1.14522380 -5.00889072 181 -4.15570795 1.14522380 182 -17.62145709 -4.15570795 183 -7.78986563 -17.62145709 184 -8.28743139 -7.78986563 185 -21.47817213 -8.28743139 186 -52.66313328 -21.47817213 187 -65.01020499 -52.66313328 188 -26.22144104 -65.01020499 189 -8.73339486 -26.22144104 190 12.94006539 -8.73339486 191 22.46891954 12.94006539 192 -30.78543929 22.46891954 193 -3.26815593 -30.78543929 194 24.24485571 -3.26815593 195 NA 24.24485571 > dum1 <- dum[2:length(myerror),] > dum1 lag(myerror, k = 1) myerror [1,] 19.42789024 14.19058595 [2,] 23.05010272 19.42789024 [3,] 31.38668939 23.05010272 [4,] 36.91416924 31.38668939 [5,] 14.03273231 36.91416924 [6,] -20.64367659 14.03273231 [7,] -24.98071397 -20.64367659 [8,] -3.23684461 -24.98071397 [9,] 4.61594304 -3.23684461 [10,] 0.49852305 4.61594304 [11,] -1.05165302 0.49852305 [12,] -26.28819193 -1.05165302 [13,] -12.62487029 -26.28819193 [14,] -10.29467411 -12.62487029 [15,] -10.21094960 -10.29467411 [16,] -16.94154396 -10.21094960 [17,] -9.55121796 -16.94154396 [18,] 13.90288529 -9.55121796 [19,] 2.01735770 13.90288529 [20,] -13.22375423 2.01735770 [21,] 1.97194037 -13.22375423 [22,] 20.18634331 1.97194037 [23,] 17.15675200 20.18634331 [24,] -2.37706238 17.15675200 [25,] -1.79189675 -2.37706238 [26,] 6.05591578 -1.79189675 [27,] -25.15763494 6.05591578 [28,] -11.21486998 -25.15763494 [29,] -10.95718707 -11.21486998 [30,] 4.53919379 -10.95718707 [31,] 14.82155055 4.53919379 [32,] 20.38017451 14.82155055 [33,] 25.93262455 20.38017451 [34,] 27.25705834 25.93262455 [35,] 25.84588168 27.25705834 [36,] -4.90128953 25.84588168 [37,] 0.65992364 -4.90128953 [38,] 17.22050909 0.65992364 [39,] 19.88663260 17.22050909 [40,] 21.15112020 19.88663260 [41,] -0.04191455 21.15112020 [42,] 43.02701463 -0.04191455 [43,] 50.85342367 43.02701463 [44,] 61.78843778 50.85342367 [45,] 57.96064916 61.78843778 [46,] 61.92912528 57.96064916 [47,] 68.16217727 61.92912528 [48,] -29.50038703 68.16217727 [49,] -37.71848396 -29.50038703 [50,] -35.09214210 -37.71848396 [51,] -10.71470391 -35.09214210 [52,] -32.77091926 -10.71470391 [53,] -14.00809700 -32.77091926 [54,] 1.39745269 -14.00809700 [55,] 10.61642187 1.39745269 [56,] 3.74165027 10.61642187 [57,] -15.47679781 3.74165027 [58,] 4.89862923 -15.47679781 [59,] 8.74975239 4.89862923 [60,] 19.04203031 8.74975239 [61,] 36.48041046 19.04203031 [62,] 34.34645293 36.48041046 [63,] 35.06804551 34.34645293 [64,] 47.75741844 35.06804551 [65,] 46.23876098 47.75741844 [66,] -5.22230468 46.23876098 [67,] -2.08806262 -5.22230468 [68,] 0.13405883 -2.08806262 [69,] -8.98731387 0.13405883 [70,] -3.53190246 -8.98731387 [71,] -5.86689998 -3.53190246 [72,] -34.66860192 -5.86689998 [73,] -33.34474463 -34.66860192 [74,] -29.94845781 -33.34474463 [75,] -8.40993393 -29.94845781 [76,] -25.06523609 -8.40993393 [77,] -24.87958145 -25.06523609 [78,] -9.08140748 -24.87958145 [79,] 21.33850230 -9.08140748 [80,] 5.56024400 21.33850230 [81,] -1.84287511 5.56024400 [82,] -6.96869113 -1.84287511 [83,] -30.64753473 -6.96869113 [84,] -4.18659827 -30.64753473 [85,] 6.03456281 -4.18659827 [86,] 17.78415375 6.03456281 [87,] 15.86727050 17.78415375 [88,] 27.34305079 15.86727050 [89,] 4.74064000 27.34305079 [90,] -3.30117988 4.74064000 [91,] 17.87954749 -3.30117988 [92,] -7.72737852 17.87954749 [93,] 18.16907360 -7.72737852 [94,] -8.38164295 18.16907360 [95,] -11.45892783 -8.38164295 [96,] -3.84454717 -11.45892783 [97,] 3.00468388 -3.84454717 [98,] 16.35892106 3.00468388 [99,] 32.86106429 16.35892106 [100,] 66.24612247 32.86106429 [101,] 26.08519158 66.24612247 [102,] 13.94186698 26.08519158 [103,] -5.05923298 13.94186698 [104,] -16.87284008 -5.05923298 [105,] -7.51576965 -16.87284008 [106,] -12.96389783 -7.51576965 [107,] -4.61134596 -12.96389783 [108,] -16.38882444 -4.61134596 [109,] -1.06586193 -16.38882444 [110,] 5.33519070 -1.06586193 [111,] 12.71566160 5.33519070 [112,] -3.50958196 12.71566160 [113,] 26.49121565 -3.50958196 [114,] 5.17675856 26.49121565 [115,] -28.12295799 5.17675856 [116,] -27.87580234 -28.12295799 [117,] -27.67492183 -27.87580234 [118,] -6.39824464 -27.67492183 [119,] 26.62355533 -6.39824464 [120,] -21.72532271 26.62355533 [121,] 5.68906355 -21.72532271 [122,] -10.46143656 5.68906355 [123,] 0.80772466 -10.46143656 [124,] -24.66690079 0.80772466 [125,] -15.31305861 -24.66690079 [126,] -12.39948003 -15.31305861 [127,] -1.34261420 -12.39948003 [128,] -19.81963112 -1.34261420 [129,] -38.69826048 -19.81963112 [130,] -25.18312597 -38.69826048 [131,] -34.80618357 -25.18312597 [132,] -27.32115221 -34.80618357 [133,] -24.60667424 -27.32115221 [134,] 11.53821187 -24.60667424 [135,] -20.79558069 11.53821187 [136,] -4.77819757 -20.79558069 [137,] -15.30336762 -4.77819757 [138,] -9.03946754 -15.30336762 [139,] -24.95319222 -9.03946754 [140,] -14.38659446 -24.95319222 [141,] 28.05932520 -14.38659446 [142,] 25.46789223 28.05932520 [143,] 24.42152346 25.46789223 [144,] 20.65719992 24.42152346 [145,] 48.26051830 20.65719992 [146,] 5.11504536 48.26051830 [147,] -6.55766791 5.11504536 [148,] -15.77233049 -6.55766791 [149,] -33.07423474 -15.77233049 [150,] -20.53383714 -33.07423474 [151,] -33.45739602 -20.53383714 [152,] -42.57240401 -33.45739602 [153,] -2.50659285 -42.57240401 [154,] -7.02678713 -2.50659285 [155,] -23.24162978 -7.02678713 [156,] -11.56377226 -23.24162978 [157,] 23.69246392 -11.56377226 [158,] 0.76411276 23.69246392 [159,] -0.89891310 0.76411276 [160,] -3.41823379 -0.89891310 [161,] -16.72534957 -3.41823379 [162,] 4.06532490 -16.72534957 [163,] -10.21530162 4.06532490 [164,] 16.91148303 -10.21530162 [165,] 48.07822170 16.91148303 [166,] 40.13212711 48.07822170 [167,] 58.26335639 40.13212711 [168,] -5.97516224 58.26335639 [169,] 33.54837996 -5.97516224 [170,] 47.77355869 33.54837996 [171,] -34.11357174 47.77355869 [172,] -33.87529826 -34.11357174 [173,] -30.33782568 -33.87529826 [174,] -27.91189677 -30.33782568 [175,] -25.88775641 -27.91189677 [176,] -26.38889007 -25.88775641 [177,] -16.49492348 -26.38889007 [178,] -15.43839527 -16.49492348 [179,] -5.00889072 -15.43839527 [180,] 1.14522380 -5.00889072 [181,] -4.15570795 1.14522380 [182,] -17.62145709 -4.15570795 [183,] -7.78986563 -17.62145709 [184,] -8.28743139 -7.78986563 [185,] -21.47817213 -8.28743139 [186,] -52.66313328 -21.47817213 [187,] -65.01020499 -52.66313328 [188,] -26.22144104 -65.01020499 [189,] -8.73339486 -26.22144104 [190,] 12.94006539 -8.73339486 [191,] 22.46891954 12.94006539 [192,] -30.78543929 22.46891954 [193,] -3.26815593 -30.78543929 [194,] 24.24485571 -3.26815593 > z <- as.data.frame(dum1) > z lag(myerror, k = 1) myerror 1 19.42789024 14.19058595 2 23.05010272 19.42789024 3 31.38668939 23.05010272 4 36.91416924 31.38668939 5 14.03273231 36.91416924 6 -20.64367659 14.03273231 7 -24.98071397 -20.64367659 8 -3.23684461 -24.98071397 9 4.61594304 -3.23684461 10 0.49852305 4.61594304 11 -1.05165302 0.49852305 12 -26.28819193 -1.05165302 13 -12.62487029 -26.28819193 14 -10.29467411 -12.62487029 15 -10.21094960 -10.29467411 16 -16.94154396 -10.21094960 17 -9.55121796 -16.94154396 18 13.90288529 -9.55121796 19 2.01735770 13.90288529 20 -13.22375423 2.01735770 21 1.97194037 -13.22375423 22 20.18634331 1.97194037 23 17.15675200 20.18634331 24 -2.37706238 17.15675200 25 -1.79189675 -2.37706238 26 6.05591578 -1.79189675 27 -25.15763494 6.05591578 28 -11.21486998 -25.15763494 29 -10.95718707 -11.21486998 30 4.53919379 -10.95718707 31 14.82155055 4.53919379 32 20.38017451 14.82155055 33 25.93262455 20.38017451 34 27.25705834 25.93262455 35 25.84588168 27.25705834 36 -4.90128953 25.84588168 37 0.65992364 -4.90128953 38 17.22050909 0.65992364 39 19.88663260 17.22050909 40 21.15112020 19.88663260 41 -0.04191455 21.15112020 42 43.02701463 -0.04191455 43 50.85342367 43.02701463 44 61.78843778 50.85342367 45 57.96064916 61.78843778 46 61.92912528 57.96064916 47 68.16217727 61.92912528 48 -29.50038703 68.16217727 49 -37.71848396 -29.50038703 50 -35.09214210 -37.71848396 51 -10.71470391 -35.09214210 52 -32.77091926 -10.71470391 53 -14.00809700 -32.77091926 54 1.39745269 -14.00809700 55 10.61642187 1.39745269 56 3.74165027 10.61642187 57 -15.47679781 3.74165027 58 4.89862923 -15.47679781 59 8.74975239 4.89862923 60 19.04203031 8.74975239 61 36.48041046 19.04203031 62 34.34645293 36.48041046 63 35.06804551 34.34645293 64 47.75741844 35.06804551 65 46.23876098 47.75741844 66 -5.22230468 46.23876098 67 -2.08806262 -5.22230468 68 0.13405883 -2.08806262 69 -8.98731387 0.13405883 70 -3.53190246 -8.98731387 71 -5.86689998 -3.53190246 72 -34.66860192 -5.86689998 73 -33.34474463 -34.66860192 74 -29.94845781 -33.34474463 75 -8.40993393 -29.94845781 76 -25.06523609 -8.40993393 77 -24.87958145 -25.06523609 78 -9.08140748 -24.87958145 79 21.33850230 -9.08140748 80 5.56024400 21.33850230 81 -1.84287511 5.56024400 82 -6.96869113 -1.84287511 83 -30.64753473 -6.96869113 84 -4.18659827 -30.64753473 85 6.03456281 -4.18659827 86 17.78415375 6.03456281 87 15.86727050 17.78415375 88 27.34305079 15.86727050 89 4.74064000 27.34305079 90 -3.30117988 4.74064000 91 17.87954749 -3.30117988 92 -7.72737852 17.87954749 93 18.16907360 -7.72737852 94 -8.38164295 18.16907360 95 -11.45892783 -8.38164295 96 -3.84454717 -11.45892783 97 3.00468388 -3.84454717 98 16.35892106 3.00468388 99 32.86106429 16.35892106 100 66.24612247 32.86106429 101 26.08519158 66.24612247 102 13.94186698 26.08519158 103 -5.05923298 13.94186698 104 -16.87284008 -5.05923298 105 -7.51576965 -16.87284008 106 -12.96389783 -7.51576965 107 -4.61134596 -12.96389783 108 -16.38882444 -4.61134596 109 -1.06586193 -16.38882444 110 5.33519070 -1.06586193 111 12.71566160 5.33519070 112 -3.50958196 12.71566160 113 26.49121565 -3.50958196 114 5.17675856 26.49121565 115 -28.12295799 5.17675856 116 -27.87580234 -28.12295799 117 -27.67492183 -27.87580234 118 -6.39824464 -27.67492183 119 26.62355533 -6.39824464 120 -21.72532271 26.62355533 121 5.68906355 -21.72532271 122 -10.46143656 5.68906355 123 0.80772466 -10.46143656 124 -24.66690079 0.80772466 125 -15.31305861 -24.66690079 126 -12.39948003 -15.31305861 127 -1.34261420 -12.39948003 128 -19.81963112 -1.34261420 129 -38.69826048 -19.81963112 130 -25.18312597 -38.69826048 131 -34.80618357 -25.18312597 132 -27.32115221 -34.80618357 133 -24.60667424 -27.32115221 134 11.53821187 -24.60667424 135 -20.79558069 11.53821187 136 -4.77819757 -20.79558069 137 -15.30336762 -4.77819757 138 -9.03946754 -15.30336762 139 -24.95319222 -9.03946754 140 -14.38659446 -24.95319222 141 28.05932520 -14.38659446 142 25.46789223 28.05932520 143 24.42152346 25.46789223 144 20.65719992 24.42152346 145 48.26051830 20.65719992 146 5.11504536 48.26051830 147 -6.55766791 5.11504536 148 -15.77233049 -6.55766791 149 -33.07423474 -15.77233049 150 -20.53383714 -33.07423474 151 -33.45739602 -20.53383714 152 -42.57240401 -33.45739602 153 -2.50659285 -42.57240401 154 -7.02678713 -2.50659285 155 -23.24162978 -7.02678713 156 -11.56377226 -23.24162978 157 23.69246392 -11.56377226 158 0.76411276 23.69246392 159 -0.89891310 0.76411276 160 -3.41823379 -0.89891310 161 -16.72534957 -3.41823379 162 4.06532490 -16.72534957 163 -10.21530162 4.06532490 164 16.91148303 -10.21530162 165 48.07822170 16.91148303 166 40.13212711 48.07822170 167 58.26335639 40.13212711 168 -5.97516224 58.26335639 169 33.54837996 -5.97516224 170 47.77355869 33.54837996 171 -34.11357174 47.77355869 172 -33.87529826 -34.11357174 173 -30.33782568 -33.87529826 174 -27.91189677 -30.33782568 175 -25.88775641 -27.91189677 176 -26.38889007 -25.88775641 177 -16.49492348 -26.38889007 178 -15.43839527 -16.49492348 179 -5.00889072 -15.43839527 180 1.14522380 -5.00889072 181 -4.15570795 1.14522380 182 -17.62145709 -4.15570795 183 -7.78986563 -17.62145709 184 -8.28743139 -7.78986563 185 -21.47817213 -8.28743139 186 -52.66313328 -21.47817213 187 -65.01020499 -52.66313328 188 -26.22144104 -65.01020499 189 -8.73339486 -26.22144104 190 12.94006539 -8.73339486 191 22.46891954 12.94006539 192 -30.78543929 22.46891954 193 -3.26815593 -30.78543929 194 24.24485571 -3.26815593 > plot(z,main=paste('Residual Lag plot, lowess, and regression line'), ylab='values of Residuals', xlab='lagged values of Residuals') > lines(lowess(z)) > abline(lm(z)) > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/7x2i21386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > acf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Autocorrelation Function') > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/8q9u31386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > pacf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Partial Autocorrelation Function') > grid() > dev.off() null device 1 > postscript(file="/var/fisher/rcomp/tmp/9or061386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > opar <- par(mfrow = c(2,2), oma = c(0, 0, 1.1, 0)) > plot(mylm, las = 1, sub='Residual Diagnostics') > par(opar) > dev.off() null device 1 > if (n > n25) { + postscript(file="/var/fisher/rcomp/tmp/10fzif1386011511.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) + plot(kp3:nmkm3,gqarr[,2], main='Goldfeld-Quandt test',ylab='2-sided p-value',xlab='breakpoint') + grid() + dev.off() + } null device 1 > > #Note: the /var/fisher/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/fisher/rcomp/createtable") > > a<-table.start() > a<-table.row.start(a) > a<-table.element(a, 'Multiple Linear Regression - Estimated Regression Equation', 1, TRUE) > a<-table.row.end(a) > myeq <- colnames(x)[1] > myeq <- paste(myeq, '[t] = ', sep='') > for (i in 1:k){ + if (mysum$coefficients[i,1] > 0) myeq <- paste(myeq, '+', '') + myeq <- paste(myeq, signif(mysum$coefficients[i,1],6), sep=' ') + if (rownames(mysum$coefficients)[i] != '(Intercept)') { + myeq <- paste(myeq, rownames(mysum$coefficients)[i], sep='') + if (rownames(mysum$coefficients)[i] != 't') myeq <- paste(myeq, '[t]', sep='') + } + } > myeq <- paste(myeq, ' + e[t]') > a<-table.row.start(a) > a<-table.element(a, myeq) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/fisher/rcomp/tmp/11el7d1386011511.tab") > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,hyperlink('http://www.xycoon.com/ols1.htm','Multiple Linear Regression - Ordinary Least Squares',''), 6, TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Variable',header=TRUE) > a<-table.element(a,'Parameter',header=TRUE) > a<-table.element(a,'S.D.',header=TRUE) > a<-table.element(a,'T-STAT
H0: parameter = 0',header=TRUE) > a<-table.element(a,'2-tail p-value',header=TRUE) > a<-table.element(a,'1-tail p-value',header=TRUE) > a<-table.row.end(a) > for (i in 1:k){ + a<-table.row.start(a) + a<-table.element(a,rownames(mysum$coefficients)[i],header=TRUE) + a<-table.element(a,signif(mysum$coefficients[i,1],6)) + a<-table.element(a, signif(mysum$coefficients[i,2],6)) + a<-table.element(a, signif(mysum$coefficients[i,3],4)) + a<-table.element(a, signif(mysum$coefficients[i,4],6)) + a<-table.element(a, signif(mysum$coefficients[i,4]/2,6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/fisher/rcomp/tmp/12n8oe1386011512.tab") > a<-table.start() > a<-table.row.start(a) > a<-table.element(a, 'Multiple Linear Regression - Regression Statistics', 2, TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Multiple R',1,TRUE) > a<-table.element(a, signif(sqrt(mysum$r.squared),6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'R-squared',1,TRUE) > a<-table.element(a, signif(mysum$r.squared,6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Adjusted R-squared',1,TRUE) > a<-table.element(a, signif(mysum$adj.r.squared,6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'F-TEST (value)',1,TRUE) > a<-table.element(a, signif(mysum$fstatistic[1],6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'F-TEST (DF numerator)',1,TRUE) > a<-table.element(a, signif(mysum$fstatistic[2],6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'F-TEST (DF denominator)',1,TRUE) > a<-table.element(a, signif(mysum$fstatistic[3],6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'p-value',1,TRUE) > a<-table.element(a, signif(1-pf(mysum$fstatistic[1],mysum$fstatistic[2],mysum$fstatistic[3]),6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Multiple Linear Regression - Residual Statistics', 2, TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Residual Standard Deviation',1,TRUE) > a<-table.element(a, signif(mysum$sigma,6)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Sum Squared Residuals',1,TRUE) > a<-table.element(a, signif(sum(myerror*myerror),6)) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/fisher/rcomp/tmp/137wgy1386011512.tab") > a<-table.start() > a<-table.row.start(a) > a<-table.element(a, 'Multiple Linear Regression - Actuals, Interpolation, and Residuals', 4, TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a, 'Time or Index', 1, TRUE) > a<-table.element(a, 'Actuals', 1, TRUE) > a<-table.element(a, 'Interpolation
Forecast', 1, TRUE) > a<-table.element(a, 'Residuals
Prediction Error', 1, TRUE) > a<-table.row.end(a) > for (i in 1:n) { + a<-table.row.start(a) + a<-table.element(a,i, 1, TRUE) + a<-table.element(a,signif(x[i],6)) + a<-table.element(a,signif(x[i]-mysum$resid[i],6)) + a<-table.element(a,signif(mysum$resid[i],6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/fisher/rcomp/tmp/14eimu1386011512.tab") > if (n > n25) { + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'Goldfeld-Quandt test for Heteroskedasticity',4,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'p-values',header=TRUE) + a<-table.element(a,'Alternative Hypothesis',3,header=TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'breakpoint index',header=TRUE) + a<-table.element(a,'greater',header=TRUE) + a<-table.element(a,'2-sided',header=TRUE) + a<-table.element(a,'less',header=TRUE) + a<-table.row.end(a) + for (mypoint in kp3:nmkm3) { + a<-table.row.start(a) + a<-table.element(a,mypoint,header=TRUE) + a<-table.element(a,signif(gqarr[mypoint-kp3+1,1],6)) + a<-table.element(a,signif(gqarr[mypoint-kp3+1,2],6)) + a<-table.element(a,signif(gqarr[mypoint-kp3+1,3],6)) + a<-table.row.end(a) + } + a<-table.end(a) + table.save(a,file="/var/fisher/rcomp/tmp/15hzko1386011512.tab") + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity',4,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'Description',header=TRUE) + a<-table.element(a,'# significant tests',header=TRUE) + a<-table.element(a,'% significant tests',header=TRUE) + a<-table.element(a,'OK/NOK',header=TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'1% type I error level',header=TRUE) + a<-table.element(a,signif(numsignificant1,6)) + a<-table.element(a,signif(numsignificant1/numgqtests,6)) + if (numsignificant1/numgqtests < 0.01) dum <- 'OK' else dum <- 'NOK' + a<-table.element(a,dum) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'5% type I error level',header=TRUE) + a<-table.element(a,signif(numsignificant5,6)) + a<-table.element(a,signif(numsignificant5/numgqtests,6)) + if (numsignificant5/numgqtests < 0.05) dum <- 'OK' else dum <- 'NOK' + a<-table.element(a,dum) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'10% type I error level',header=TRUE) + a<-table.element(a,signif(numsignificant10,6)) + a<-table.element(a,signif(numsignificant10/numgqtests,6)) + if (numsignificant10/numgqtests < 0.1) dum <- 'OK' else dum <- 'NOK' + a<-table.element(a,dum) + a<-table.row.end(a) + a<-table.end(a) + table.save(a,file="/var/fisher/rcomp/tmp/169set1386011512.tab") + } > > try(system("convert tmp/1o66a1386011511.ps tmp/1o66a1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/29jgk1386011511.ps tmp/29jgk1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/3akny1386011511.ps tmp/3akny1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/4otza1386011511.ps tmp/4otza1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/59zdl1386011511.ps tmp/59zdl1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/6nnzf1386011511.ps tmp/6nnzf1386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/7x2i21386011511.ps tmp/7x2i21386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/8q9u31386011511.ps tmp/8q9u31386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/9or061386011511.ps tmp/9or061386011511.png",intern=TRUE)) character(0) > try(system("convert tmp/10fzif1386011511.ps tmp/10fzif1386011511.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 13.322 2.349 15.659