R version 2.9.0 (2009-04-17) Copyright (C) 2009 The R Foundation for Statistical Computing ISBN 3-900051-07-0 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 <- c(2938,2909,3141,2427,3059,2918,2901,2823,2798,2892,2967,2397,3458,3024,3100,2904,3056,2771,2897,2772,2857,3020,2648,2364,3194,3013,2560,3074,2746,2846,3184,2354,3080,2963,2430,2296,2416,2647,2789,2685,2666,2882,2953,2127,2563,3061,2809,2861,2781,2555,3206,2570,2410,3195,2736,2743,2934,2668,2907,2866,2983,2878,3225,2515,3193,2663,2908,2896,2853,3028,3053,2455,3401,2969,3243,2849,3296,3121,3194,3023,2984,3525,3116,2383,3294,2882,2820,2583,2803,2767,2945,2716,2644,2956,2598,2171,2994,2645,2724,2550,2707,2679,2878,2307,2496,2637,2436,2426,2607,2533,2888,2520,2229,2804,2661,2547,2509,2465,2629,2706,2666,2432,2836,2888,2566,2802,2611,2683,2675,2434,2693,2619,2903,2550,2900,2456,2912,2883,2464,2655,2447,2592,2698,2274,2901,2397,3004,2614,2882,2671,2761,2806,2414,2673,2748,2112,2903,2633,2684,2861,2504,2708,2961,2535,2688,2699,2469,2585,2582,2480,2709,2441,2182,2585,2881,2422,2690,2659,2535,2613) > par4 = '12' > par3 = '0' > par2 = '0' > par1 = '1' > #'GNU S' R Code compiled by R2WASP v. 1.0.44 () > #Author: Prof. Dr. P. Wessa > #To cite this work: AUTHOR(S), (YEAR), YOUR SOFTWARE TITLE (vNUMBER) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_YOURPAGE.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > #Technical description: Write here your technical program description (don't use hard returns!) > par1 <- as.numeric(par1) > par2 <- as.numeric(par2) > par3 <- as.numeric(par3) > par4 <- as.numeric(par4) > if (par1 == 0) { + x <- log(x) + } else { + x <- (x ^ par1 - 1) / par1 + } > if (par2 > 0) x <- diff(x,lag=1,difference=par2) > if (par3 > 0) x <- diff(x,lag=par4,difference=par3) > postscript(file="/var/www/html/rcomp/tmp/1u7w51291972899.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > r <- spectrum(x,main='Raw Periodogram') > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/2nzdq1291972899.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > cpgram(x,main='Cumulative Periodogram') > dev.off() null device 1 > > #Note: the /var/www/html/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/html/rcomp/createtable") > > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Raw Periodogram',2,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Parameter',header=TRUE) > a<-table.element(a,'Value',header=TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Box-Cox transformation parameter (lambda)',header=TRUE) > a<-table.element(a,par1) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Degree of non-seasonal differencing (d)',header=TRUE) > a<-table.element(a,par2) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Degree of seasonal differencing (D)',header=TRUE) > a<-table.element(a,par3) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Seasonal Period (s)',header=TRUE) > a<-table.element(a,par4) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Frequency (Period)',header=TRUE) > a<-table.element(a,'Spectrum',header=TRUE) > a<-table.row.end(a) > for (i in 1:length(r$freq)) { + a<-table.row.start(a) + mylab <- round(r$freq[i],4) + mylab <- paste(mylab,' (',sep='') + mylab <- paste(mylab,round(1/r$freq[i],4),sep='') + mylab <- paste(mylab,')',sep='') + a<-table.element(a,mylab,header=TRUE) + a<-table.element(a,round(r$spec[i],6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/31qsz1291972899.tab") > try(system("convert tmp/1u7w51291972899.ps tmp/1u7w51291972899.png",intern=TRUE)) character(0) > try(system("convert tmp/2nzdq1291972899.ps tmp/2nzdq1291972899.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 0.554 0.330 1.439