R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 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(1 + ,1 + ,41 + ,38 + ,13 + ,12 + ,14 + ,1 + ,1 + ,39 + ,32 + ,16 + ,11 + ,18 + ,1 + ,1 + ,30 + ,35 + ,19 + ,15 + ,11 + ,1 + ,0 + ,31 + ,33 + ,15 + ,6 + ,12 + ,1 + ,1 + ,34 + ,37 + ,14 + ,13 + ,16 + ,1 + ,1 + ,35 + ,29 + ,13 + ,10 + ,18 + ,1 + ,1 + ,39 + ,31 + ,19 + ,12 + ,14 + ,1 + ,1 + ,34 + ,36 + ,15 + ,14 + ,14 + ,1 + ,1 + ,36 + ,35 + ,14 + ,12 + ,15 + ,1 + ,1 + ,37 + ,38 + ,15 + ,9 + ,15 + ,1 + ,0 + ,38 + ,31 + ,16 + ,10 + ,17 + ,1 + ,1 + ,36 + ,34 + ,16 + ,12 + ,19 + ,1 + ,0 + ,38 + ,35 + ,16 + ,12 + ,10 + ,1 + ,1 + ,39 + ,38 + ,16 + ,11 + ,16 + ,1 + ,1 + ,33 + ,37 + ,17 + ,15 + ,18 + ,1 + ,0 + ,32 + ,33 + ,15 + ,12 + ,14 + ,1 + ,0 + ,36 + ,32 + ,15 + ,10 + ,14 + ,1 + ,1 + ,38 + ,38 + ,20 + ,12 + ,17 + ,1 + ,0 + ,39 + ,38 + ,18 + ,11 + ,14 + ,1 + ,1 + ,32 + ,32 + ,16 + ,12 + ,16 + ,1 + ,0 + ,32 + ,33 + ,16 + ,11 + ,18 + ,1 + ,1 + ,31 + ,31 + ,16 + ,12 + ,11 + ,1 + ,1 + ,39 + ,38 + ,19 + ,13 + ,14 + ,1 + ,1 + ,37 + ,39 + ,16 + ,11 + ,12 + ,1 + ,0 + ,39 + ,32 + ,17 + ,12 + ,17 + ,1 + ,1 + ,41 + ,32 + ,17 + ,13 + ,9 + ,1 + ,0 + ,36 + ,35 + ,16 + ,10 + ,16 + ,1 + ,1 + ,33 + ,37 + ,15 + ,14 + ,14 + ,1 + ,1 + ,33 + ,33 + ,16 + ,12 + ,15 + ,1 + ,0 + ,34 + ,33 + ,14 + ,10 + ,11 + ,1 + ,1 + ,31 + ,31 + ,15 + ,12 + ,16 + ,1 + ,0 + ,27 + ,32 + ,12 + ,8 + ,13 + ,1 + ,1 + ,37 + ,31 + ,14 + ,10 + ,17 + ,1 + ,1 + ,34 + ,37 + ,16 + ,12 + ,15 + ,1 + ,0 + ,34 + ,30 + ,14 + ,12 + ,14 + ,1 + ,0 + ,32 + ,33 + ,10 + ,7 + ,16 + ,1 + ,0 + ,29 + ,31 + ,10 + ,9 + ,9 + ,1 + ,0 + ,36 + ,33 + ,14 + ,12 + ,15 + ,1 + ,1 + ,29 + ,31 + ,16 + ,10 + ,17 + ,1 + ,0 + ,35 + ,33 + ,16 + ,10 + ,13 + ,1 + ,0 + ,37 + ,32 + ,16 + ,10 + ,15 + ,1 + ,1 + ,34 + ,33 + ,14 + ,12 + ,16 + ,1 + ,0 + ,38 + ,32 + ,20 + ,15 + ,16 + ,1 + ,0 + ,35 + ,33 + ,14 + ,10 + ,12 + ,1 + ,1 + ,38 + ,28 + ,14 + ,10 + ,15 + ,1 + ,1 + ,37 + ,35 + ,11 + ,12 + ,11 + ,1 + ,1 + ,38 + ,39 + ,14 + ,13 + ,15 + ,1 + ,1 + ,33 + ,34 + ,15 + ,11 + ,15 + ,1 + ,1 + ,36 + ,38 + ,16 + ,11 + ,17 + ,1 + ,0 + ,38 + ,32 + ,14 + ,12 + ,13 + ,1 + ,1 + ,32 + ,38 + ,16 + ,14 + ,16 + ,1 + ,0 + ,32 + ,30 + ,14 + ,10 + ,14 + ,1 + ,0 + ,32 + ,33 + ,12 + ,12 + ,11 + ,1 + ,1 + ,34 + ,38 + ,16 + ,13 + ,12 + ,1 + ,0 + ,32 + ,32 + ,9 + ,5 + ,12 + ,1 + ,1 + ,37 + ,35 + ,14 + ,6 + ,15 + ,1 + ,1 + ,39 + ,34 + ,16 + ,12 + ,16 + ,1 + ,1 + ,29 + ,34 + ,16 + ,12 + ,15 + ,1 + ,0 + ,37 + ,36 + ,15 + ,11 + ,12 + ,1 + ,1 + ,35 + ,34 + ,16 + ,10 + ,12 + ,1 + ,0 + ,30 + ,28 + ,12 + ,7 + ,8 + ,1 + ,0 + ,38 + ,34 + ,16 + ,12 + ,13 + ,1 + ,1 + ,34 + ,35 + ,16 + ,14 + ,11 + ,1 + ,1 + ,31 + ,35 + ,14 + ,11 + ,14 + ,1 + ,1 + ,34 + ,31 + ,16 + ,12 + ,15 + ,1 + ,0 + ,35 + ,37 + ,17 + ,13 + ,10 + ,1 + ,1 + ,36 + ,35 + ,18 + ,14 + ,11 + ,1 + ,0 + ,30 + ,27 + ,18 + ,11 + ,12 + ,1 + ,1 + ,39 + ,40 + ,12 + ,12 + ,15 + ,1 + ,0 + ,35 + ,37 + ,16 + ,12 + ,15 + ,1 + ,0 + ,38 + ,36 + ,10 + ,8 + ,14 + ,1 + ,1 + ,31 + ,38 + ,14 + ,11 + ,16 + ,1 + ,1 + ,34 + ,39 + ,18 + ,14 + ,15 + ,1 + ,0 + ,38 + ,41 + ,18 + ,14 + ,15 + ,1 + ,0 + ,34 + ,27 + ,16 + ,12 + ,13 + ,1 + ,1 + ,39 + ,30 + ,17 + ,9 + ,12 + ,1 + ,1 + ,37 + ,37 + ,16 + ,13 + ,17 + ,1 + ,1 + ,34 + ,31 + ,16 + ,11 + ,13 + ,1 + ,0 + ,28 + ,31 + ,13 + ,12 + ,15 + ,1 + ,0 + ,37 + ,27 + ,16 + ,12 + ,13 + ,1 + ,0 + ,33 + ,36 + ,16 + ,12 + ,15 + ,1 + ,1 + ,35 + ,37 + ,16 + ,12 + ,15 + ,1 + ,0 + ,37 + ,33 + ,15 + ,12 + ,16 + ,1 + ,1 + ,32 + ,34 + ,15 + ,11 + ,15 + ,1 + ,1 + ,33 + ,31 + ,16 + ,10 + ,14 + ,1 + ,0 + ,38 + ,39 + ,14 + ,9 + ,15 + ,1 + ,1 + ,33 + ,34 + ,16 + ,12 + ,14 + ,1 + ,1 + ,29 + ,32 + ,16 + ,12 + ,13 + ,1 + ,1 + ,33 + ,33 + ,15 + ,12 + ,7 + ,1 + ,1 + ,31 + ,36 + ,12 + ,9 + ,17 + ,1 + ,1 + ,36 + ,32 + ,17 + ,15 + ,13 + ,1 + ,1 + ,35 + ,41 + ,16 + ,12 + ,15 + ,1 + ,1 + ,32 + ,28 + ,15 + ,12 + ,14 + ,1 + ,1 + ,29 + ,30 + ,13 + ,12 + ,13 + ,1 + ,1 + ,39 + ,36 + ,16 + ,10 + ,16 + ,1 + ,1 + ,37 + ,35 + ,16 + ,13 + ,12 + ,1 + ,1 + ,35 + ,31 + ,16 + ,9 + ,14 + ,1 + ,0 + ,37 + ,34 + ,16 + ,12 + ,17 + ,1 + ,0 + ,32 + ,36 + ,14 + ,10 + ,15 + ,1 + ,1 + ,38 + ,36 + ,16 + ,14 + ,17 + ,1 + ,0 + ,37 + ,35 + ,16 + ,11 + ,12 + ,1 + ,1 + ,36 + ,37 + ,20 + ,15 + ,16 + ,1 + ,0 + ,32 + ,28 + ,15 + ,11 + ,11 + ,1 + ,1 + ,33 + ,39 + ,16 + ,11 + ,15 + ,1 + ,0 + ,40 + ,32 + ,13 + ,12 + ,9 + ,1 + ,1 + ,38 + ,35 + ,17 + ,12 + ,16 + ,1 + ,0 + ,41 + ,39 + ,16 + ,12 + ,15 + ,1 + ,0 + ,36 + ,35 + ,16 + ,11 + ,10 + ,1 + ,1 + ,43 + ,42 + ,12 + ,7 + ,10 + ,1 + ,1 + ,30 + ,34 + ,16 + ,12 + ,15 + ,1 + ,1 + ,31 + ,33 + ,16 + ,14 + ,11 + ,1 + ,1 + ,32 + ,41 + ,17 + ,11 + ,13 + ,1 + ,1 + ,37 + ,34 + ,12 + ,10 + ,18 + ,1 + ,0 + ,37 + ,32 + ,18 + ,13 + ,16 + ,1 + ,1 + ,33 + ,40 + ,14 + ,13 + ,14 + ,1 + ,1 + ,34 + ,40 + ,14 + ,8 + ,14 + ,1 + ,1 + ,33 + ,35 + ,13 + ,11 + ,14 + ,1 + ,1 + ,38 + ,36 + ,16 + ,12 + ,14 + ,1 + ,0 + ,33 + ,37 + ,13 + ,11 + ,12 + ,1 + ,1 + ,31 + ,27 + ,16 + ,13 + ,14 + ,1 + ,1 + ,38 + ,39 + ,13 + ,12 + ,15 + ,1 + ,1 + ,37 + ,38 + ,16 + ,14 + ,15 + ,1 + ,1 + ,36 + ,31 + ,15 + ,13 + ,15 + ,1 + ,1 + ,31 + ,33 + ,16 + ,15 + ,13 + ,1 + ,0 + ,39 + ,32 + ,15 + ,10 + ,17 + ,1 + ,1 + ,44 + ,39 + ,17 + ,11 + ,17 + ,1 + ,1 + ,33 + ,36 + ,15 + ,9 + ,19 + ,1 + ,1 + ,35 + ,33 + ,12 + ,11 + ,15 + ,1 + ,0 + ,32 + ,33 + ,16 + ,10 + ,13 + ,1 + ,0 + ,28 + ,32 + ,10 + ,11 + ,9 + ,1 + ,1 + ,40 + ,37 + ,16 + ,8 + ,15 + ,1 + ,0 + ,27 + ,30 + ,12 + ,11 + ,15 + ,1 + ,0 + ,37 + ,38 + ,14 + ,12 + ,15 + ,1 + ,1 + ,32 + ,29 + ,15 + ,12 + ,16 + ,1 + ,0 + ,28 + ,22 + ,13 + ,9 + ,11 + ,1 + ,0 + ,34 + ,35 + ,15 + ,11 + ,14 + ,1 + ,1 + ,30 + ,35 + ,11 + ,10 + ,11 + ,1 + ,1 + ,35 + ,34 + ,12 + ,8 + ,15 + ,1 + ,0 + ,31 + ,35 + ,11 + ,9 + ,13 + ,1 + ,1 + ,32 + ,34 + ,16 + ,8 + ,15 + ,1 + ,0 + ,30 + ,37 + ,15 + ,9 + ,16 + ,1 + ,1 + ,30 + ,35 + ,17 + ,15 + ,14 + ,1 + ,0 + ,31 + ,23 + ,16 + ,11 + ,15 + ,1 + ,1 + ,40 + ,31 + ,10 + ,8 + ,16 + ,1 + ,1 + ,32 + ,27 + ,18 + ,13 + ,16 + ,1 + ,0 + ,36 + ,36 + ,13 + ,12 + ,11 + ,1 + ,0 + ,32 + ,31 + ,16 + ,12 + ,12 + ,1 + ,0 + ,35 + ,32 + ,13 + ,9 + ,9 + ,1 + ,1 + ,38 + ,39 + ,10 + ,7 + ,16 + ,1 + ,1 + ,42 + ,37 + ,15 + ,13 + ,13 + ,1 + ,0 + ,34 + ,38 + ,16 + ,9 + ,16 + ,1 + ,1 + ,35 + ,39 + ,16 + ,6 + ,12 + ,1 + ,1 + ,38 + ,34 + ,14 + ,8 + ,9 + ,1 + ,1 + ,33 + ,31 + ,10 + ,8 + ,13 + ,1 + ,1 + ,32 + ,37 + ,13 + ,6 + ,14 + ,1 + ,1 + ,33 + ,36 + ,15 + ,9 + ,19 + ,1 + ,1 + ,34 + ,32 + ,16 + ,11 + ,13 + ,1 + ,1 + ,32 + ,38 + ,12 + ,8 + ,12 + ,0 + ,0 + ,27 + ,26 + ,13 + ,10 + ,10 + ,0 + ,0 + ,31 + ,26 + ,12 + ,8 + ,14 + ,0 + ,0 + ,38 + ,33 + ,17 + ,14 + ,16 + ,0 + ,1 + ,34 + ,39 + ,15 + ,10 + ,10 + ,0 + ,0 + ,24 + ,30 + ,10 + ,8 + ,11 + ,0 + ,0 + ,30 + ,33 + ,14 + ,11 + ,14 + ,0 + ,1 + ,26 + ,25 + ,11 + ,12 + ,12 + ,0 + ,1 + ,34 + ,38 + ,13 + ,12 + ,9 + ,0 + ,0 + ,27 + ,37 + ,16 + ,12 + ,9 + ,0 + ,0 + ,37 + ,31 + ,12 + ,5 + ,11 + ,0 + ,1 + ,36 + ,37 + ,16 + ,12 + ,16 + ,0 + ,0 + ,41 + ,35 + ,12 + ,10 + ,9 + ,0 + ,1 + ,29 + ,25 + ,9 + ,7 + ,13 + ,0 + ,1 + ,36 + ,28 + ,12 + ,12 + ,16 + ,0 + ,0 + ,32 + ,35 + ,15 + ,11 + ,13 + ,0 + ,1 + ,37 + ,33 + ,12 + ,8 + ,9 + ,0 + ,0 + ,30 + ,30 + ,12 + ,9 + ,12 + ,0 + ,1 + ,31 + ,31 + ,14 + ,10 + ,16 + ,0 + ,1 + ,38 + ,37 + ,12 + ,9 + ,11 + ,0 + ,1 + ,36 + ,36 + ,16 + ,12 + ,14 + ,0 + ,0 + ,35 + ,30 + ,11 + ,6 + ,13 + ,0 + ,0 + ,31 + ,36 + ,19 + ,15 + ,15 + ,0 + ,0 + ,38 + ,32 + ,15 + ,12 + ,14 + ,0 + ,1 + ,22 + ,28 + ,8 + ,12 + ,16 + ,0 + ,1 + ,32 + ,36 + ,16 + ,12 + ,13 + ,0 + ,0 + ,36 + ,34 + ,17 + ,11 + ,14 + ,0 + ,1 + ,39 + ,31 + ,12 + ,7 + ,15 + ,0 + ,0 + ,28 + ,28 + ,11 + ,7 + ,13 + ,0 + ,0 + ,32 + ,36 + ,11 + ,5 + ,11 + ,0 + ,1 + ,32 + ,36 + ,14 + ,12 + ,11 + ,0 + ,1 + ,38 + ,40 + ,16 + ,12 + ,14 + ,0 + ,1 + ,32 + ,33 + ,12 + ,3 + ,15 + ,0 + ,1 + ,35 + ,37 + ,16 + ,11 + ,11 + ,0 + ,1 + ,32 + ,32 + ,13 + ,10 + ,15 + ,0 + ,0 + ,37 + ,38 + ,15 + ,12 + ,12 + ,0 + ,1 + ,34 + ,31 + ,16 + ,9 + ,14 + ,0 + ,1 + ,33 + ,37 + ,16 + ,12 + ,14 + ,0 + ,0 + ,33 + ,33 + ,14 + ,9 + ,8 + ,0 + ,0 + ,30 + ,30 + ,16 + ,12 + ,9 + ,0 + ,0 + ,24 + ,30 + ,14 + ,10 + ,15 + ,0 + ,0 + ,34 + ,31 + ,11 + ,9 + ,17 + ,0 + ,0 + ,34 + ,32 + ,12 + ,12 + ,13 + ,0 + ,1 + ,33 + ,34 + ,15 + ,8 + ,15 + ,0 + ,1 + ,34 + ,36 + ,15 + ,11 + ,15 + ,0 + ,1 + ,35 + ,37 + ,16 + ,11 + ,14 + ,0 + ,0 + ,35 + ,36 + ,16 + ,12 + ,16 + ,0 + ,0 + ,36 + ,33 + ,11 + ,10 + ,13 + ,0 + ,0 + ,34 + ,33 + ,15 + ,10 + ,16 + ,0 + ,1 + ,34 + ,33 + ,12 + ,12 + ,9 + ,0 + ,0 + ,41 + ,44 + ,12 + ,12 + ,16 + ,0 + ,0 + ,32 + ,39 + ,15 + ,11 + ,11 + ,0 + ,0 + ,30 + ,32 + ,15 + ,8 + ,10 + ,0 + ,1 + ,35 + ,35 + ,16 + ,12 + ,11 + ,0 + ,0 + ,28 + ,25 + ,14 + ,10 + ,15 + ,0 + ,1 + ,33 + ,35 + ,17 + ,11 + ,17 + ,0 + ,1 + ,39 + ,34 + ,14 + ,10 + ,14 + ,0 + ,0 + ,36 + ,35 + ,13 + ,8 + ,8 + ,0 + ,1 + ,36 + ,39 + ,15 + ,12 + ,15 + ,0 + ,0 + ,35 + ,33 + ,13 + ,12 + ,11 + ,0 + ,0 + ,38 + ,36 + ,14 + ,10 + ,16 + ,0 + ,1 + ,33 + ,32 + ,15 + ,12 + ,10 + ,0 + ,0 + ,31 + ,32 + ,12 + ,9 + ,15 + ,0 + ,1 + ,32 + ,36 + ,8 + ,6 + ,16 + ,0 + ,0 + ,31 + ,32 + ,14 + ,10 + ,19 + ,0 + ,0 + ,33 + ,34 + ,14 + ,9 + ,12 + ,0 + ,0 + ,34 + ,33 + ,11 + ,9 + ,8 + ,0 + ,0 + ,34 + ,35 + ,12 + ,9 + ,11 + ,0 + ,1 + ,34 + ,30 + ,13 + ,6 + ,14 + ,0 + ,0 + ,33 + ,38 + ,10 + ,10 + ,9 + ,0 + ,0 + ,32 + ,34 + ,16 + ,6 + ,15 + ,0 + ,1 + ,41 + ,33 + ,18 + ,14 + ,13 + ,0 + ,1 + ,34 + ,32 + ,13 + ,10 + ,16 + ,0 + ,0 + ,36 + ,31 + ,11 + ,10 + ,11 + ,0 + ,0 + ,37 + ,30 + ,4 + ,6 + ,12 + ,0 + ,0 + ,36 + ,27 + ,13 + ,12 + ,13 + ,0 + ,1 + ,29 + ,31 + ,16 + ,12 + ,10 + ,0 + ,0 + ,37 + ,30 + ,10 + ,7 + ,11 + ,0 + ,0 + ,27 + ,32 + ,12 + ,8 + ,12 + ,0 + ,0 + ,35 + ,35 + ,12 + ,11 + ,8 + ,0 + ,0 + ,28 + ,28 + ,10 + ,3 + ,12 + ,0 + ,0 + ,35 + ,33 + ,13 + ,6 + ,12 + ,0 + ,0 + ,29 + ,35 + ,12 + ,8 + ,11 + ,0 + ,0 + ,32 + ,35 + ,14 + ,9 + ,13 + ,0 + ,1 + ,36 + ,32 + ,10 + ,9 + ,14 + ,0 + ,1 + ,19 + ,21 + ,12 + ,8 + ,10 + ,0 + ,1 + ,21 + ,20 + ,12 + ,9 + ,12 + ,0 + ,0 + ,31 + ,34 + ,11 + ,7 + ,15 + ,0 + ,0 + ,33 + ,32 + ,10 + ,7 + ,13 + ,0 + ,1 + ,36 + ,34 + ,12 + ,6 + ,13 + ,0 + ,1 + ,33 + ,32 + ,16 + ,9 + ,13 + ,0 + ,0 + ,37 + ,33 + ,12 + ,10 + ,12 + ,0 + ,0 + ,34 + ,33 + ,14 + ,11 + ,12 + ,0 + ,0 + ,35 + ,37 + ,16 + ,12 + ,9 + ,0 + ,1 + ,31 + ,32 + ,14 + ,8 + ,9 + ,0 + ,1 + ,37 + ,34 + ,13 + ,11 + ,15 + ,0 + ,1 + ,35 + ,30 + ,4 + ,3 + ,10 + ,0 + ,1 + ,27 + ,30 + ,15 + ,11 + ,14 + ,0 + ,0 + ,34 + ,38 + ,11 + ,12 + ,15 + ,0 + ,0 + ,40 + ,36 + ,11 + ,7 + ,7 + ,0 + ,0 + ,29 + ,32 + ,14 + ,9 + ,14 + ,0 + ,0 + ,38 + ,34 + ,15 + ,12 + ,8 + ,0 + ,1 + ,34 + ,33 + ,14 + ,8 + ,10 + ,0 + ,0 + ,21 + ,27 + ,13 + ,11 + ,13 + ,0 + ,0 + ,36 + ,32 + ,11 + ,8 + ,13 + ,0 + ,1 + ,38 + ,34 + ,15 + ,10 + ,13 + ,0 + ,0 + ,30 + ,29 + ,11 + ,8 + ,8 + ,0 + ,0 + ,35 + ,35 + ,13 + ,7 + ,12 + ,0 + ,1 + ,30 + ,27 + ,13 + ,8 + ,13 + ,0 + ,1 + ,36 + ,33 + ,16 + ,10 + ,12 + ,0 + ,0 + ,34 + ,38 + ,13 + ,8 + ,10 + ,0 + ,1 + ,35 + ,36 + ,16 + ,12 + ,13 + ,0 + ,0 + ,34 + ,33 + ,16 + ,14 + ,12 + ,0 + ,0 + ,32 + ,39 + ,12 + ,7 + ,9 + ,0 + ,1 + ,33 + ,29 + ,7 + ,6 + ,15 + ,0 + ,0 + ,33 + ,32 + ,16 + ,11 + ,13 + ,0 + ,1 + ,26 + ,34 + ,5 + ,4 + ,13 + ,0 + ,0 + ,35 + ,38 + ,16 + ,9 + ,13 + ,0 + ,0 + ,21 + ,17 + ,4 + ,5 + ,15 + ,0 + ,0 + ,38 + ,35 + ,12 + ,9 + ,15 + ,0 + ,0 + ,35 + ,32 + ,15 + ,11 + ,14 + ,0 + ,1 + ,33 + ,34 + ,14 + ,12 + ,15 + ,0 + ,0 + ,37 + ,36 + ,11 + ,9 + ,11 + ,0 + ,0 + ,38 + ,31 + ,16 + ,12 + ,15 + ,0 + ,1 + ,34 + ,35 + ,15 + ,10 + ,14 + ,0 + ,0 + ,27 + ,29 + ,12 + ,9 + ,13 + ,0 + ,1 + ,16 + ,22 + ,6 + ,6 + ,12 + ,0 + ,0 + ,40 + ,41 + ,16 + ,10 + ,16 + ,0 + ,0 + ,36 + ,36 + ,10 + ,9 + ,16 + ,0 + ,1 + ,42 + ,42 + ,15 + ,13 + ,9 + ,0 + ,1 + ,30 + ,33 + ,14 + ,12 + ,14) + ,dim=c(7 + ,288) + ,dimnames=list(c('Pop' + ,'Gender' + ,'Connected' + ,'Separate' + ,'Learning' + ,'Software' + ,'Happiness') + ,1:288)) > y <- array(NA,dim=c(7,288),dimnames=list(c('Pop','Gender','Connected','Separate','Learning','Software','Happiness'),1:288)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > par20 = '' > par19 = '' > par18 = '' > par17 = '' > par16 = '' > par15 = '' > par14 = '' > par13 = '' > par12 = '' > par11 = '' > par10 = '' > par9 = '' > par8 = '' > par7 = '' > par6 = '' > par5 = '' > par4 = 'no' > par3 = '2' > par2 = 'none' > par1 = '7' > library(party) Loading required package: survival Loading required package: splines Loading required package: grid Loading required package: modeltools Loading required package: stats4 Loading required package: coin Loading required package: mvtnorm Loading required package: zoo Attaching package: 'zoo' The following object(s) are masked from 'package:base': as.Date, as.Date.numeric Loading required package: sandwich Loading required package: strucchange Loading required package: vcd Loading required package: MASS Loading required package: colorspace > library(Hmisc) Hmisc library by Frank E Harrell Jr Type library(help='Hmisc'), ?Overview, or ?Hmisc.Overview') to see overall documentation. NOTE:Hmisc no longer redefines [.factor to drop unused levels when subsetting. To get the old behavior of Hmisc type dropUnusedLevels(). Attaching package: 'Hmisc' The following object(s) are masked from 'package:survival': untangle.specials The following object(s) are masked from 'package:base': format.pval, round.POSIXt, trunc.POSIXt, units > par1 <- as.numeric(par1) > par3 <- as.numeric(par3) > x <- data.frame(t(y)) > is.data.frame(x) [1] TRUE > x <- x[!is.na(x[,par1]),] > k <- length(x[1,]) > n <- length(x[,1]) > colnames(x)[par1] [1] "Happiness" > x[,par1] [1] 14 18 11 12 16 18 14 14 15 15 17 19 10 16 18 14 14 17 14 16 18 11 14 12 17 [26] 9 16 14 15 11 16 13 17 15 14 16 9 15 17 13 15 16 16 12 15 11 15 15 17 13 [51] 16 14 11 12 12 15 16 15 12 12 8 13 11 14 15 10 11 12 15 15 14 16 15 15 13 [76] 12 17 13 15 13 15 15 16 15 14 15 14 13 7 17 13 15 14 13 16 12 14 17 15 17 [101] 12 16 11 15 9 16 15 10 10 15 11 13 18 16 14 14 14 14 12 14 15 15 15 13 17 [126] 17 19 15 13 9 15 15 15 16 11 14 11 15 13 15 16 14 15 16 16 11 12 9 16 13 [151] 16 12 9 13 14 19 13 12 10 14 16 10 11 14 12 9 9 11 16 9 13 16 13 9 12 [176] 16 11 14 13 15 14 16 13 14 15 13 11 11 14 15 11 15 12 14 14 8 9 15 17 13 [201] 15 15 14 16 13 16 9 16 11 10 11 15 17 14 8 15 11 16 10 15 16 19 12 8 11 [226] 14 9 15 13 16 11 12 13 10 11 12 8 12 12 11 13 14 10 12 15 13 13 13 12 12 [251] 9 9 15 10 14 15 7 14 8 10 13 13 13 8 12 13 12 10 13 12 9 15 13 13 13 [276] 15 15 14 15 11 15 14 13 12 16 16 9 14 > if (par2 == 'kmeans') { + cl <- kmeans(x[,par1], par3) + print(cl) + clm <- matrix(cbind(cl$centers,1:par3),ncol=2) + clm <- clm[sort.list(clm[,1]),] + for (i in 1:par3) { + cl$cluster[cl$cluster==clm[i,2]] <- paste('C',i,sep='') + } + cl$cluster <- as.factor(cl$cluster) + print(cl$cluster) + x[,par1] <- cl$cluster + } > if (par2 == 'quantiles') { + x[,par1] <- cut2(x[,par1],g=par3) + } > if (par2 == 'hclust') { + hc <- hclust(dist(x[,par1])^2, 'cen') + print(hc) + memb <- cutree(hc, k = par3) + dum <- c(mean(x[memb==1,par1])) + for (i in 2:par3) { + dum <- c(dum, mean(x[memb==i,par1])) + } + hcm <- matrix(cbind(dum,1:par3),ncol=2) + hcm <- hcm[sort.list(hcm[,1]),] + for (i in 1:par3) { + memb[memb==hcm[i,2]] <- paste('C',i,sep='') + } + memb <- as.factor(memb) + print(memb) + x[,par1] <- memb + } > if (par2=='equal') { + ed <- cut(as.numeric(x[,par1]),par3,labels=paste('C',1:par3,sep='')) + x[,par1] <- as.factor(ed) + } > table(x[,par1]) 7 8 9 10 11 12 13 14 15 16 17 18 19 2 7 17 13 26 30 39 41 55 35 14 5 4 > colnames(x) [1] "Pop" "Gender" "Connected" "Separate" "Learning" "Software" [7] "Happiness" > colnames(x)[par1] [1] "Happiness" > x[,par1] [1] 14 18 11 12 16 18 14 14 15 15 17 19 10 16 18 14 14 17 14 16 18 11 14 12 17 [26] 9 16 14 15 11 16 13 17 15 14 16 9 15 17 13 15 16 16 12 15 11 15 15 17 13 [51] 16 14 11 12 12 15 16 15 12 12 8 13 11 14 15 10 11 12 15 15 14 16 15 15 13 [76] 12 17 13 15 13 15 15 16 15 14 15 14 13 7 17 13 15 14 13 16 12 14 17 15 17 [101] 12 16 11 15 9 16 15 10 10 15 11 13 18 16 14 14 14 14 12 14 15 15 15 13 17 [126] 17 19 15 13 9 15 15 15 16 11 14 11 15 13 15 16 14 15 16 16 11 12 9 16 13 [151] 16 12 9 13 14 19 13 12 10 14 16 10 11 14 12 9 9 11 16 9 13 16 13 9 12 [176] 16 11 14 13 15 14 16 13 14 15 13 11 11 14 15 11 15 12 14 14 8 9 15 17 13 [201] 15 15 14 16 13 16 9 16 11 10 11 15 17 14 8 15 11 16 10 15 16 19 12 8 11 [226] 14 9 15 13 16 11 12 13 10 11 12 8 12 12 11 13 14 10 12 15 13 13 13 12 12 [251] 9 9 15 10 14 15 7 14 8 10 13 13 13 8 12 13 12 10 13 12 9 15 13 13 13 [276] 15 15 14 15 11 15 14 13 12 16 16 9 14 > if (par2 == 'none') { + m <- ctree(as.formula(paste(colnames(x)[par1],' ~ .',sep='')),data = x) + } > > #Note: the /var/wessaorg/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/wessaorg/rcomp/createtable") > > if (par2 != 'none') { + m <- ctree(as.formula(paste('as.factor(',colnames(x)[par1],') ~ .',sep='')),data = x) + if (par4=='yes') { + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'10-Fold Cross Validation',3+2*par3,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'',1,TRUE) + a<-table.element(a,'Prediction (training)',par3+1,TRUE) + a<-table.element(a,'Prediction (testing)',par3+1,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'Actual',1,TRUE) + for (jjj in 1:par3) a<-table.element(a,paste('C',jjj,sep=''),1,TRUE) + a<-table.element(a,'CV',1,TRUE) + for (jjj in 1:par3) a<-table.element(a,paste('C',jjj,sep=''),1,TRUE) + a<-table.element(a,'CV',1,TRUE) + a<-table.row.end(a) + for (i in 1:10) { + ind <- sample(2, nrow(x), replace=T, prob=c(0.9,0.1)) + m.ct <- ctree(as.formula(paste('as.factor(',colnames(x)[par1],') ~ .',sep='')),data =x[ind==1,]) + if (i==1) { + m.ct.i.pred <- predict(m.ct, newdata=x[ind==1,]) + m.ct.i.actu <- x[ind==1,par1] + m.ct.x.pred <- predict(m.ct, newdata=x[ind==2,]) + m.ct.x.actu <- x[ind==2,par1] + } else { + m.ct.i.pred <- c(m.ct.i.pred,predict(m.ct, newdata=x[ind==1,])) + m.ct.i.actu <- c(m.ct.i.actu,x[ind==1,par1]) + m.ct.x.pred <- c(m.ct.x.pred,predict(m.ct, newdata=x[ind==2,])) + m.ct.x.actu <- c(m.ct.x.actu,x[ind==2,par1]) + } + } + print(m.ct.i.tab <- table(m.ct.i.actu,m.ct.i.pred)) + numer <- 0 + for (i in 1:par3) { + print(m.ct.i.tab[i,i] / sum(m.ct.i.tab[i,])) + numer <- numer + m.ct.i.tab[i,i] + } + print(m.ct.i.cp <- numer / sum(m.ct.i.tab)) + print(m.ct.x.tab <- table(m.ct.x.actu,m.ct.x.pred)) + numer <- 0 + for (i in 1:par3) { + print(m.ct.x.tab[i,i] / sum(m.ct.x.tab[i,])) + numer <- numer + m.ct.x.tab[i,i] + } + print(m.ct.x.cp <- numer / sum(m.ct.x.tab)) + for (i in 1:par3) { + a<-table.row.start(a) + a<-table.element(a,paste('C',i,sep=''),1,TRUE) + for (jjj in 1:par3) a<-table.element(a,m.ct.i.tab[i,jjj]) + a<-table.element(a,round(m.ct.i.tab[i,i]/sum(m.ct.i.tab[i,]),4)) + for (jjj in 1:par3) a<-table.element(a,m.ct.x.tab[i,jjj]) + a<-table.element(a,round(m.ct.x.tab[i,i]/sum(m.ct.x.tab[i,]),4)) + a<-table.row.end(a) + } + a<-table.row.start(a) + a<-table.element(a,'Overall',1,TRUE) + for (jjj in 1:par3) a<-table.element(a,'-') + a<-table.element(a,round(m.ct.i.cp,4)) + for (jjj in 1:par3) a<-table.element(a,'-') + a<-table.element(a,round(m.ct.x.cp,4)) + a<-table.row.end(a) + a<-table.end(a) + table.save(a,file="/var/wessaorg/rcomp/tmp/1il9n1355160376.tab") + } + } > m Conditional inference tree with 4 terminal nodes Response: Happiness Inputs: Pop, Gender, Connected, Separate, Learning, Software Number of observations: 288 1) Pop <= 0; criterion = 1, statistic = 21.842 2)* weights = 130 1) Pop > 0 3) Gender <= 0; criterion = 0.956, statistic = 7.153 4) Learning <= 13; criterion = 0.974, statistic = 8.115 5)* weights = 16 4) Learning > 13 6)* weights = 44 3) Gender > 0 7)* weights = 98 > postscript(file="/var/wessaorg/rcomp/tmp/29oln1355160376.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(m) > dev.off() null device 1 > postscript(file="/var/wessaorg/rcomp/tmp/35eys1355160376.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(x[,par1] ~ as.factor(where(m)),main='Response by Terminal Node',xlab='Terminal Node',ylab='Response') > dev.off() null device 1 > if (par2 == 'none') { + forec <- predict(m) + result <- as.data.frame(cbind(x[,par1],forec,x[,par1]-forec)) + colnames(result) <- c('Actuals','Forecasts','Residuals') + print(result) + } Actuals Forecasts Residuals 1 14 14.44898 -0.44897959 2 18 14.44898 3.55102041 3 11 14.44898 -3.44897959 4 12 14.04545 -2.04545455 5 16 14.44898 1.55102041 6 18 14.44898 3.55102041 7 14 14.44898 -0.44897959 8 14 14.44898 -0.44897959 9 15 14.44898 0.55102041 10 15 14.44898 0.55102041 11 17 14.04545 2.95454545 12 19 14.44898 4.55102041 13 10 14.04545 -4.04545455 14 16 14.44898 1.55102041 15 18 14.44898 3.55102041 16 14 14.04545 -0.04545455 17 14 14.04545 -0.04545455 18 17 14.44898 2.55102041 19 14 14.04545 -0.04545455 20 16 14.44898 1.55102041 21 18 14.04545 3.95454545 22 11 14.44898 -3.44897959 23 14 14.44898 -0.44897959 24 12 14.44898 -2.44897959 25 17 14.04545 2.95454545 26 9 14.44898 -5.44897959 27 16 14.04545 1.95454545 28 14 14.44898 -0.44897959 29 15 14.44898 0.55102041 30 11 14.04545 -3.04545455 31 16 14.44898 1.55102041 32 13 11.68750 1.31250000 33 17 14.44898 2.55102041 34 15 14.44898 0.55102041 35 14 14.04545 -0.04545455 36 16 11.68750 4.31250000 37 9 11.68750 -2.68750000 38 15 14.04545 0.95454545 39 17 14.44898 2.55102041 40 13 14.04545 -1.04545455 41 15 14.04545 0.95454545 42 16 14.44898 1.55102041 43 16 14.04545 1.95454545 44 12 14.04545 -2.04545455 45 15 14.44898 0.55102041 46 11 14.44898 -3.44897959 47 15 14.44898 0.55102041 48 15 14.44898 0.55102041 49 17 14.44898 2.55102041 50 13 14.04545 -1.04545455 51 16 14.44898 1.55102041 52 14 14.04545 -0.04545455 53 11 11.68750 -0.68750000 54 12 14.44898 -2.44897959 55 12 11.68750 0.31250000 56 15 14.44898 0.55102041 57 16 14.44898 1.55102041 58 15 14.44898 0.55102041 59 12 14.04545 -2.04545455 60 12 14.44898 -2.44897959 61 8 11.68750 -3.68750000 62 13 14.04545 -1.04545455 63 11 14.44898 -3.44897959 64 14 14.44898 -0.44897959 65 15 14.44898 0.55102041 66 10 14.04545 -4.04545455 67 11 14.44898 -3.44897959 68 12 14.04545 -2.04545455 69 15 14.44898 0.55102041 70 15 14.04545 0.95454545 71 14 11.68750 2.31250000 72 16 14.44898 1.55102041 73 15 14.44898 0.55102041 74 15 14.04545 0.95454545 75 13 14.04545 -1.04545455 76 12 14.44898 -2.44897959 77 17 14.44898 2.55102041 78 13 14.44898 -1.44897959 79 15 11.68750 3.31250000 80 13 14.04545 -1.04545455 81 15 14.04545 0.95454545 82 15 14.44898 0.55102041 83 16 14.04545 1.95454545 84 15 14.44898 0.55102041 85 14 14.44898 -0.44897959 86 15 14.04545 0.95454545 87 14 14.44898 -0.44897959 88 13 14.44898 -1.44897959 89 7 14.44898 -7.44897959 90 17 14.44898 2.55102041 91 13 14.44898 -1.44897959 92 15 14.44898 0.55102041 93 14 14.44898 -0.44897959 94 13 14.44898 -1.44897959 95 16 14.44898 1.55102041 96 12 14.44898 -2.44897959 97 14 14.44898 -0.44897959 98 17 14.04545 2.95454545 99 15 14.04545 0.95454545 100 17 14.44898 2.55102041 101 12 14.04545 -2.04545455 102 16 14.44898 1.55102041 103 11 14.04545 -3.04545455 104 15 14.44898 0.55102041 105 9 11.68750 -2.68750000 106 16 14.44898 1.55102041 107 15 14.04545 0.95454545 108 10 14.04545 -4.04545455 109 10 14.44898 -4.44897959 110 15 14.44898 0.55102041 111 11 14.44898 -3.44897959 112 13 14.44898 -1.44897959 113 18 14.44898 3.55102041 114 16 14.04545 1.95454545 115 14 14.44898 -0.44897959 116 14 14.44898 -0.44897959 117 14 14.44898 -0.44897959 118 14 14.44898 -0.44897959 119 12 11.68750 0.31250000 120 14 14.44898 -0.44897959 121 15 14.44898 0.55102041 122 15 14.44898 0.55102041 123 15 14.44898 0.55102041 124 13 14.44898 -1.44897959 125 17 14.04545 2.95454545 126 17 14.44898 2.55102041 127 19 14.44898 4.55102041 128 15 14.44898 0.55102041 129 13 14.04545 -1.04545455 130 9 11.68750 -2.68750000 131 15 14.44898 0.55102041 132 15 11.68750 3.31250000 133 15 14.04545 0.95454545 134 16 14.44898 1.55102041 135 11 11.68750 -0.68750000 136 14 14.04545 -0.04545455 137 11 14.44898 -3.44897959 138 15 14.44898 0.55102041 139 13 11.68750 1.31250000 140 15 14.44898 0.55102041 141 16 14.04545 1.95454545 142 14 14.44898 -0.44897959 143 15 14.04545 0.95454545 144 16 14.44898 1.55102041 145 16 14.44898 1.55102041 146 11 11.68750 -0.68750000 147 12 14.04545 -2.04545455 148 9 11.68750 -2.68750000 149 16 14.44898 1.55102041 150 13 14.44898 -1.44897959 151 16 14.04545 1.95454545 152 12 14.44898 -2.44897959 153 9 14.44898 -5.44897959 154 13 14.44898 -1.44897959 155 14 14.44898 -0.44897959 156 19 14.44898 4.55102041 157 13 14.44898 -1.44897959 158 12 14.44898 -2.44897959 159 10 12.67692 -2.67692308 160 14 12.67692 1.32307692 161 16 12.67692 3.32307692 162 10 12.67692 -2.67692308 163 11 12.67692 -1.67692308 164 14 12.67692 1.32307692 165 12 12.67692 -0.67692308 166 9 12.67692 -3.67692308 167 9 12.67692 -3.67692308 168 11 12.67692 -1.67692308 169 16 12.67692 3.32307692 170 9 12.67692 -3.67692308 171 13 12.67692 0.32307692 172 16 12.67692 3.32307692 173 13 12.67692 0.32307692 174 9 12.67692 -3.67692308 175 12 12.67692 -0.67692308 176 16 12.67692 3.32307692 177 11 12.67692 -1.67692308 178 14 12.67692 1.32307692 179 13 12.67692 0.32307692 180 15 12.67692 2.32307692 181 14 12.67692 1.32307692 182 16 12.67692 3.32307692 183 13 12.67692 0.32307692 184 14 12.67692 1.32307692 185 15 12.67692 2.32307692 186 13 12.67692 0.32307692 187 11 12.67692 -1.67692308 188 11 12.67692 -1.67692308 189 14 12.67692 1.32307692 190 15 12.67692 2.32307692 191 11 12.67692 -1.67692308 192 15 12.67692 2.32307692 193 12 12.67692 -0.67692308 194 14 12.67692 1.32307692 195 14 12.67692 1.32307692 196 8 12.67692 -4.67692308 197 9 12.67692 -3.67692308 198 15 12.67692 2.32307692 199 17 12.67692 4.32307692 200 13 12.67692 0.32307692 201 15 12.67692 2.32307692 202 15 12.67692 2.32307692 203 14 12.67692 1.32307692 204 16 12.67692 3.32307692 205 13 12.67692 0.32307692 206 16 12.67692 3.32307692 207 9 12.67692 -3.67692308 208 16 12.67692 3.32307692 209 11 12.67692 -1.67692308 210 10 12.67692 -2.67692308 211 11 12.67692 -1.67692308 212 15 12.67692 2.32307692 213 17 12.67692 4.32307692 214 14 12.67692 1.32307692 215 8 12.67692 -4.67692308 216 15 12.67692 2.32307692 217 11 12.67692 -1.67692308 218 16 12.67692 3.32307692 219 10 12.67692 -2.67692308 220 15 12.67692 2.32307692 221 16 12.67692 3.32307692 222 19 12.67692 6.32307692 223 12 12.67692 -0.67692308 224 8 12.67692 -4.67692308 225 11 12.67692 -1.67692308 226 14 12.67692 1.32307692 227 9 12.67692 -3.67692308 228 15 12.67692 2.32307692 229 13 12.67692 0.32307692 230 16 12.67692 3.32307692 231 11 12.67692 -1.67692308 232 12 12.67692 -0.67692308 233 13 12.67692 0.32307692 234 10 12.67692 -2.67692308 235 11 12.67692 -1.67692308 236 12 12.67692 -0.67692308 237 8 12.67692 -4.67692308 238 12 12.67692 -0.67692308 239 12 12.67692 -0.67692308 240 11 12.67692 -1.67692308 241 13 12.67692 0.32307692 242 14 12.67692 1.32307692 243 10 12.67692 -2.67692308 244 12 12.67692 -0.67692308 245 15 12.67692 2.32307692 246 13 12.67692 0.32307692 247 13 12.67692 0.32307692 248 13 12.67692 0.32307692 249 12 12.67692 -0.67692308 250 12 12.67692 -0.67692308 251 9 12.67692 -3.67692308 252 9 12.67692 -3.67692308 253 15 12.67692 2.32307692 254 10 12.67692 -2.67692308 255 14 12.67692 1.32307692 256 15 12.67692 2.32307692 257 7 12.67692 -5.67692308 258 14 12.67692 1.32307692 259 8 12.67692 -4.67692308 260 10 12.67692 -2.67692308 261 13 12.67692 0.32307692 262 13 12.67692 0.32307692 263 13 12.67692 0.32307692 264 8 12.67692 -4.67692308 265 12 12.67692 -0.67692308 266 13 12.67692 0.32307692 267 12 12.67692 -0.67692308 268 10 12.67692 -2.67692308 269 13 12.67692 0.32307692 270 12 12.67692 -0.67692308 271 9 12.67692 -3.67692308 272 15 12.67692 2.32307692 273 13 12.67692 0.32307692 274 13 12.67692 0.32307692 275 13 12.67692 0.32307692 276 15 12.67692 2.32307692 277 15 12.67692 2.32307692 278 14 12.67692 1.32307692 279 15 12.67692 2.32307692 280 11 12.67692 -1.67692308 281 15 12.67692 2.32307692 282 14 12.67692 1.32307692 283 13 12.67692 0.32307692 284 12 12.67692 -0.67692308 285 16 12.67692 3.32307692 286 16 12.67692 3.32307692 287 9 12.67692 -3.67692308 288 14 12.67692 1.32307692 > if (par2 != 'none') { + print(cbind(as.factor(x[,par1]),predict(m))) + myt <- table(as.factor(x[,par1]),predict(m)) + print(myt) + } > postscript(file="/var/wessaorg/rcomp/tmp/4zrsq1355160376.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > if(par2=='none') { + op <- par(mfrow=c(2,2)) + plot(density(result$Actuals),main='Kernel Density Plot of Actuals') + plot(density(result$Residuals),main='Kernel Density Plot of Residuals') + plot(result$Forecasts,result$Actuals,main='Actuals versus Predictions',xlab='Predictions',ylab='Actuals') + plot(density(result$Forecasts),main='Kernel Density Plot of Predictions') + par(op) + } > if(par2!='none') { + plot(myt,main='Confusion Matrix',xlab='Actual',ylab='Predicted') + } > dev.off() null device 1 > if (par2 == 'none') { + detcoef <- cor(result$Forecasts,result$Actuals) + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'Goodness of Fit',2,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'Correlation',1,TRUE) + a<-table.element(a,round(detcoef,4)) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'R-squared',1,TRUE) + a<-table.element(a,round(detcoef*detcoef,4)) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'RMSE',1,TRUE) + a<-table.element(a,round(sqrt(mean((result$Residuals)^2)),4)) + a<-table.row.end(a) + a<-table.end(a) + table.save(a,file="/var/wessaorg/rcomp/tmp/5c0c81355160376.tab") + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'Actuals, Predictions, and Residuals',4,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'#',header=TRUE) + a<-table.element(a,'Actuals',header=TRUE) + a<-table.element(a,'Forecasts',header=TRUE) + a<-table.element(a,'Residuals',header=TRUE) + a<-table.row.end(a) + for (i in 1:length(result$Actuals)) { + a<-table.row.start(a) + a<-table.element(a,i,header=TRUE) + a<-table.element(a,result$Actuals[i]) + a<-table.element(a,result$Forecasts[i]) + a<-table.element(a,result$Residuals[i]) + a<-table.row.end(a) + } + a<-table.end(a) + table.save(a,file="/var/wessaorg/rcomp/tmp/60pc51355160376.tab") + } > if (par2 != 'none') { + a<-table.start() + a<-table.row.start(a) + a<-table.element(a,'Confusion Matrix (predicted in columns / actuals in rows)',par3+1,TRUE) + a<-table.row.end(a) + a<-table.row.start(a) + a<-table.element(a,'',1,TRUE) + for (i in 1:par3) { + a<-table.element(a,paste('C',i,sep=''),1,TRUE) + } + a<-table.row.end(a) + for (i in 1:par3) { + a<-table.row.start(a) + a<-table.element(a,paste('C',i,sep=''),1,TRUE) + for (j in 1:par3) { + a<-table.element(a,myt[i,j]) + } + a<-table.row.end(a) + } + a<-table.end(a) + table.save(a,file="/var/wessaorg/rcomp/tmp/7aiqc1355160376.tab") + } > > try(system("convert tmp/29oln1355160376.ps tmp/29oln1355160376.png",intern=TRUE)) character(0) > try(system("convert tmp/35eys1355160376.ps tmp/35eys1355160376.png",intern=TRUE)) character(0) > try(system("convert tmp/4zrsq1355160376.ps tmp/4zrsq1355160376.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 7.303 0.441 7.725