R version 2.8.1 (2008-12-22) Copyright (C) 2008 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(4283956.79 + ,7183777.99 + ,4583968.38 + ,6784773.41 + ,978501.69 + ,3385277.37 + ,3387808.9 + ,5090372.5 + ,9794012.05 + ,3594907.03 + ,9095799.33 + ,8896654.21 + ,22100254.64 + ,39100848.94 + ,58101965.77 + ,4103558.24 + ,74104492.86 + ,29105421.25 + ,3106489.48 + ,45107590.19 + ,84110056.49 + ,14110732.74 + ,15111589.41 + ,83111896.81 + ,3114475 + ,30114961.53 + ,11115067.6 + ,16115709.65 + ,10116343.39 + ,36117121.14 + ,31117946.87 + ,66119418.26 + ,10121305.01 + ,16120503.75 + ,42119020.44 + ,80117308.33 + ,30119531.74 + ,82119049.14 + ,34118370.78 + ,30116842.6 + ,24114896.94 + ,67113414.17 + ,24111722.39 + ,14110421.75 + ,70110491.05 + ,30108544.61 + ,53106037.19 + ,54102918.04 + ,73104219.84 + ,58102942.54 + ,87101366.74 + ,9796645.61 + ,6091687.72 + ,6086956.1 + ,1685945.37 + ,1686437.21 + ,8587139.8 + ,7087349.95 + ,5786752.73 + ,886074.15 + ,2789146 + ,4889370.14 + ,5089425.11 + ,9489201.56 + ,8988986.11 + ,7988935.99 + ,6288845.45 + ,2390074.93 + ,9991714.93 + ,7491907.69 + ,8490806.02 + ,6689821.5 + ,1293059.74 + ,6593118.58 + ,3293172.05 + ,2193303.86 + ,593595.11 + ,1492674.7 + ,4791505.46 + ,1092941.42 + ,8293499.88 + ,593076.57 + ,9492152.61 + ,8091675.54 + ,7294921.2 + ,4895098.02 + ,6595113.57 + ,494901.22 + ,2994804.35 + ,7794869.79 + ,7694587.35 + ,7996651.38 + ,3098005.97 + ,5398287.88 + ,6898451.57 + ,2798396.44 + ,79102377.15 + ,60103121.91 + ,7103536.77 + ,95103852.46 + ,5104195.03 + ,8104566.45 + ,83105279.63 + ,56106488.55 + ,61106896.09 + ,31108371.05 + ,14109227.75 + ,7109861.25) > par1 = '0' > ylab = 'Density' > xlab = 'Value' > #'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: > if (par1 == '0') bw <- 'nrd0' > if (par1 != '0') bw <- as.numeric(par1) > postscript(file="/var/www/html/rcomp/tmp/127gq1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity1<-density(x,bw=bw,kernel='gaussian',na.rm=TRUE) > plot(mydensity1,main='Gaussian Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > mydensity1 Call: density.default(x = x, bw = bw, kernel = "gaussian", na.rm = TRUE) Data: x (108 obs.); Bandwidth 'bw' = 6.707e+06 x y Min. :-19626378 Min. :6.315e-12 1st Qu.: 14086499 1st Qu.:2.554e-09 Median : 47799377 Median :4.165e-09 Mean : 47799377 Mean :7.407e-09 3rd Qu.: 81512254 3rd Qu.:6.742e-09 Max. :115225132 Max. :3.511e-08 > postscript(file="/var/www/html/rcomp/tmp/2pikz1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity2<-density(x,bw=bw,kernel='epanechnikov',na.rm=TRUE) > plot(mydensity2,main='Epanechnikov Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/3pmjy1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity3<-density(x,bw=bw,kernel='rectangular',na.rm=TRUE) > plot(mydensity3,main='Rectangular Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/4gk8m1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity4<-density(x,bw=bw,kernel='triangular',na.rm=TRUE) > plot(mydensity4,main='Triangular Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/5o7ct1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity5<-density(x,bw=bw,kernel='biweight',na.rm=TRUE) > plot(mydensity5,main='Biweight Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/6mffs1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity6<-density(x,bw=bw,kernel='cosine',na.rm=TRUE) > plot(mydensity6,main='Cosine Kernel',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/7xd3t1234811919.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > mydensity7<-density(x,bw=bw,kernel='optcosine',na.rm=TRUE) > plot(mydensity7,main='Optcosine Kernel',xlab=xlab,ylab=ylab) > grid() > 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,'Properties of Density Trace',2,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Bandwidth',header=TRUE) > a<-table.element(a,mydensity1$bw) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'#Observations',header=TRUE) > a<-table.element(a,mydensity1$n) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/80m1p1234811919.tab") > > system("convert tmp/127gq1234811919.ps tmp/127gq1234811919.png") > system("convert tmp/2pikz1234811919.ps tmp/2pikz1234811919.png") > system("convert tmp/3pmjy1234811919.ps tmp/3pmjy1234811919.png") > system("convert tmp/4gk8m1234811919.ps tmp/4gk8m1234811919.png") > system("convert tmp/5o7ct1234811919.ps tmp/5o7ct1234811919.png") > system("convert tmp/6mffs1234811919.ps tmp/6mffs1234811919.png") > system("convert tmp/7xd3t1234811919.ps tmp/7xd3t1234811919.png") > > > proc.time() user system elapsed 1.352 1.159 2.266