Home » date » 2008 » Nov » 08 »

Q2 Hierarchical Clustering

*The author of this computation has been verified*
R Software Module: rwasp_hierarchicalclustering.wasp (opens new window with default values)
Title produced by software: Hierarchical Clustering
Date of computation: Sat, 08 Nov 2008 05:46:45 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh.htm/, Retrieved Sat, 08 Nov 2008 12:47:34 +0000
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh.htm/},
    year = {2008},
}
@Manual{R,
    title = {R: A Language and Environment for Statistical Computing},
    author = {{R Development Core Team}},
    organization = {R Foundation for Statistical Computing},
    address = {Vienna, Austria},
    year = {2008},
    note = {{ISBN} 3-900051-07-0},
    url = {http://www.R-project.org},
}
 
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
 
Feedback Forum:

Post a new message
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
109.8 148.8 118.3 110.3 111.7 146.7 127.3 114.8 98.6 118.8 112.3 94.6 96.9 99.4 114.9 92 95.1 97.6 108.2 93.8 97 110.2 105.4 93.8 112.7 146.6 122.1 107.6 102.9 136.4 113.5 101 97.4 126.2 110 95.4 111.4 154.9 125.3 96.5 87.4 109 114.3 89.2 96.8 128.5 115.6 87.1 114.1 144.9 127.1 110.5 110.3 136.3 123 110.8 103.9 134.8 122.2 104.2 101.6 103.4 126.4 88.9 94.6 106.6 112.7 89.8 95.9 119.2 105.8 90 104.7 149.3 120.9 93.9 102.8 150.2 116.3 91.3 98.1 142.9 115.7 87.8 113.9 163.6 127.9 99.7 80.9 98.2 108.3 73.5 95.7 138.2 121.1 79.2 113.2 143.7 128.6 96.9 105.9 132.8 123.1 95.2 108.8 149.4 127.7 95.6 102.3 128.8 126.6 89.7 99 98.9 118.4 92.8 100.7 106.2 110 88 115.5 140.7 129.6 101.1 100.7 133 115.8 92.7 109.9 156.4 125.9 95.8 114.6 157.7 128.4 103.8 85.4 107.9 114 81.8 100.5 133.6 125.6 87.1 114.8 148.1 128.5 105.9 116.5 205.6 136.6 108.1 112.9 193.1 133.1 102.6 102 117.5 124.6 93.7 106 116.4 123.5 103.5 105.3 129.5 117.2 100.6 118.8 157.1 135.5 113.3 106.1 157 124.8 102.4 109.3 158.4 127.8 102.1 117.2 161.7 133.1 106.9 92.5 116.9 125.7 87.3 104.2 161.1 128.4 93.1 112.5 155.7 131.9 109.1 122.4 160.8 146.3 120.3 113.3 145.4 140.6 104.9 100 111 129.5 92.6 110.7 144.8 132.4 109.8 112.8 149.2 125.9 111.4 109.8 156.6 126.9 117.9 117.3 182.5 135.8 121.6 109.1 171.3 129.5 117.8 115.9 172.7 130.2 124.2 96 133 133.8 106.8 97.6 148.1 123.3 100.9
 
Output produced by software:

Enter (or paste) a matrix (table) containing all data (time) series. Every column represents a different variable and must be delimited by a space or Tab. Every row represents a period in time (or category) and must be delimited by hard returns. The easiest way to enter data is to copy and paste a block of spreadsheet cells. Please, do not use commas or spaces to seperate groups of digits!


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Summary of Dendrogram
LabelHeight
12.31300670124408
24.18927201313068
34.58039299623950
44.61410879802374
55.12849296353602
65.68682688324518
75.73846669416142
85.83438085832592
95.91438923304851
106.92098258919932
116.98212002188447
127.62364742101836
137.74983870799903
147.88225855957543
157.94115570231299
168.17679643870386
178.19878039710786
188.45399313933954
198.5057982855388
209.07156186831972
219.14004933124971
229.46836839165018
239.58581927896433
2410.0751449484902
2510.4125797550762
2610.702000817405
2710.8919110126347
2811.0136236810983
2911.4442125111342
3012.569425267137
3113.0023252126165
3213.7466072788174
3314.3346266451543
3414.5502577296761
3515.0075419335415
3615.0953674629106
3715.6308638135530
3816.2637412624147
3916.5339307568122
4016.9955730315128
4117.4031677326043
4219.5876995966315
4320.3226366603704
4421.2143572606957
4523.3188212342353
4624.2686321723351
4727.6415380997149
4831.4119996674662
4933.7652240625095
5039.6074135103671
5140.7994691936216
5247.4371132914931
5351.3664581475435
5468.5807933588385
5588.0766563900602
5690.119397994664
57160.61112212819
58247.395704984203
59659.263321866696
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh/1p5mu1226148403.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh/1p5mu1226148403.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh/2riv51226148403.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Nov/08/t1226148451vgzkf4sank6ensh/2riv51226148403.ps (open in new window)


 
Parameters (Session):
par1 = ward ; par2 = ALL ; par3 = FALSE ; par4 = FALSE ;
 
Parameters (R input):
par1 = ward ; par2 = ALL ; par3 = FALSE ; par4 = FALSE ;
 
R code (references can be found in the software module):
par3 <- as.logical(par3)
par4 <- as.logical(par4)
if (par3 == 'TRUE'){
dum = xlab
xlab = ylab
ylab = dum
}
x <- t(y)
hc <- hclust(dist(x),method=par1)
d <- as.dendrogram(hc)
str(d)
mysub <- paste('Method: ',par1)
bitmap(file='test1.png')
if (par4 == 'TRUE'){
plot(d,main=main,ylab=ylab,xlab=xlab,horiz=par3, nodePar=list(pch = c(1,NA), cex=0.8, lab.cex = 0.8),type='t',center=T, sub=mysub)
} else {
plot(d,main=main,ylab=ylab,xlab=xlab,horiz=par3, nodePar=list(pch = c(1,NA), cex=0.8, lab.cex = 0.8), sub=mysub)
}
dev.off()
if (par2 != 'ALL'){
if (par3 == 'TRUE'){
ylab = 'cluster'
} else {
xlab = 'cluster'
}
par2 <- as.numeric(par2)
memb <- cutree(hc, k = par2)
cent <- NULL
for(k in 1:par2){
cent <- rbind(cent, colMeans(x[memb == k, , drop = FALSE]))
}
hc1 <- hclust(dist(cent),method=par1, members = table(memb))
de <- as.dendrogram(hc1)
bitmap(file='test2.png')
if (par4 == 'TRUE'){
plot(de,main=main,ylab=ylab,xlab=xlab,horiz=par3, nodePar=list(pch = c(1,NA), cex=0.8, lab.cex = 0.8),type='t',center=T, sub=mysub)
} else {
plot(de,main=main,ylab=ylab,xlab=xlab,horiz=par3, nodePar=list(pch = c(1,NA), cex=0.8, lab.cex = 0.8), sub=mysub)
}
dev.off()
str(de)
}
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Summary of Dendrogram',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Label',header=TRUE)
a<-table.element(a,'Height',header=TRUE)
a<-table.row.end(a)
num <- length(x[,1])-1
for (i in 1:num)
{
a<-table.row.start(a)
a<-table.element(a,hc$labels[i])
a<-table.element(a,hc$height[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable1.tab')
if (par2 != 'ALL'){
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Summary of Cut Dendrogram',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Label',header=TRUE)
a<-table.element(a,'Height',header=TRUE)
a<-table.row.end(a)
num <- par2-1
for (i in 1:num)
{
a<-table.row.start(a)
a<-table.element(a,i)
a<-table.element(a,hc1$height[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable2.tab')
}
 





Copyright

Creative Commons License

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 License.

Software written by Ed van Stee & Patrick Wessa


Disclaimer

Information provided on this web site is provided "AS IS" without warranty of any kind, either express or implied, including, without limitation, warranties of merchantability, fitness for a particular purpose, and noninfringement. We use reasonable efforts to include accurate and timely information and periodically update the information, and software without notice. However, we make no warranties or representations as to the accuracy or completeness of such information (or software), and we assume no liability or responsibility for errors or omissions in the content of this web site, or any software bugs in online applications. Your use of this web site is AT YOUR OWN RISK. Under no circumstances and under no legal theory shall we be liable to you or any other person for any direct, indirect, special, incidental, exemplary, or consequential damages arising from your access to, or use of, this web site.


Privacy Policy

We may request personal information to be submitted to our servers in order to be able to:

  • personalize online software applications according to your needs
  • enforce strict security rules with respect to the data that you upload (e.g. statistical data)
  • manage user sessions of online applications
  • alert you about important changes or upgrades in resources or applications

We NEVER allow other companies to directly offer registered users information about their products and services. Banner references and hyperlinks of third parties NEVER contain any personal data of the visitor.

We do NOT sell, nor transmit by any means, personal information, nor statistical data series uploaded by you to third parties.

We carefully protect your data from loss, misuse, alteration, and destruction. However, at any time, and under any circumstance you are solely responsible for managing your passwords, and keeping them secret.

We store a unique ANONYMOUS USER ID in the form of a small 'Cookie' on your computer. This allows us to track your progress when using this website which is necessary to create state-dependent features. The cookie is used for NO OTHER PURPOSE. At any time you may opt to disallow cookies from this website - this will not affect other features of this website.

We examine cookies that are used by third-parties (banner and online ads) very closely: abuse from third-parties automatically results in termination of the advertising contract without refund. We have very good reason to believe that the cookies that are produced by third parties (banner ads) do NOT cause any privacy or security risk.

FreeStatistics.org is safe. There is no need to download any software to use the applications and services contained in this website. Hence, your system's security is not compromised by their use, and your personal data - other than data you submit in the account application form, and the user-agent information that is transmitted by your browser - is never transmitted to our servers.

As a general rule, we do not log on-line behavior of individuals (other than normal logging of webserver 'hits'). However, in cases of abuse, hacking, unauthorized access, Denial of Service attacks, illegal copying, hotlinking, non-compliance with international webstandards (such as robots.txt), or any other harmful behavior, our system engineers are empowered to log, track, identify, publish, and ban misbehaving individuals - even if this leads to ban entire blocks of IP addresses, or disclosing user's identity.


FreeStatistics.org is powered by