similar to: plot.hclust

Displaying 20 results from an estimated 6000 matches similar to: "plot.hclust"

2009 Apr 03
0
dendrogram rect.hclust() not working?
I have tried to use rect.hclust() to draw a rectangle around a set of leaves, but am running into trouble. The rect.hclust() is drawing two rects instead of one, and of the wrong size: -------------------- scoreClusterObj <- hclust(scoreDistanceObj, method=clustMethod) order <- scoreClusterObj$order orderedLabels <- rep(0, length(order)) for (orderIndex in 1:length(order)) { # this
2008 Jun 02
1
Plotting horizontal dendrograms
I am using hclust and plot to produce dendrograms. Using my input data I am able to complete an analysis and obtain a vertical plot. I want to be able to plot the dendrogram horizontally.I am using version 2.6 of R and have updated my packages recently. Using the sample script for dendrograms I can produce a horizontal plot using the instruction horiz = TRUE in plot(). When I use the same
2007 May 24
0
rotating an hclust tree with negative hights
Hi, I have an hclust object say hcl with heights starting from a negative and ending to a positive value. I would like to rotate the plot(hcl) 90 degrees clockwise. It is suggested to use plot(as.dendogram(hcl), horiz=T) but I encountered two problems: 1) a dendrogram object does not accept negative heights 2) horiz=T rotates the tree 90 degrees unclockwise any ideas? thanks, Vahid PARTOVI
2005 Jan 25
2
Plotting hclust with lot of objects
Hi! I am newbee to R and I am facing the problem in plotting the dedrogram with lot of objects. The lines and labels are overlapped very badly, and writing the graphic to postscript and zooming there is not helping either. I tried cut.dendrogram method, but getting the error that it doesn't exist even though I get the man pages for it. I would not find any solution in web as well, and I
2011 Jan 28
1
axis name editing
Dear All, I'm generating a heatmap, is there a way to make Y axis name display horizontally, X axis name display vertically? I tried using "horiz=TRUE": axis(1,at=1:dim(cor.meta.m)[1],labels=gsub("module","",pw.names),horiz=T RUE) but got warning message and the name is not displayed as I wish: Warning message: In axis(1, at = 1:dim(cor.meta.m)[1],
2000 May 31
1
legend with multiple columns
I have made a minor hack to "legend" (in R 1.0.0, but I didn't notice any changes to legend in the 1.0.1 NEWS) to allow the legend to be formatted in multiple columns, or horizontally (number of columns <- number of legend items). (I find this helpful when I have lots of legend items and not a lot of vertical space to squeeze the legend into.) (Another hack I've considered
2006 Aug 30
1
How to put title Vertically
Dear all R users, Suppose, Dear all R users, Suppose, pauto.cor = pacf(lh, plot=F) max.lag = max(pauto.cor$lag) min.lag = min(pauto.cor$lag) centre = (max.lag - min.lag)/2 pauto.cor = pauto.cor$acf pauto.cor = pauto.cor[-1] par(mar=c(3,0,1,1)) barplot(pauto.cor, axes=F,xlim=c(max(pauto.cor), min(pauto.cor)), space=0, col="green4",border="green",horiz=T) #This plots
2007 Jun 13
2
Formatted Data File Question for Clustering -Quickie Project
I am trying to learn how to format Ascii data files for scan or read into R. Precisely for a quickie project, I found some code (at end of this email) to do exactly what I need: To cluster and graph a dendrogram from package (stats). I am stuck on how to format a text file to run the script. I looked at the dataset USArrests (which would be replaced by my data and labels) using UltraEdit. That
2007 Aug 02
2
plot to postscript orientation
Hi I am trying to save some plots in a postscript file. When I generate the plots in the main window, they appear correctly - their orientation is landscape (i.e., horizontal). However, when I open the .ps file with GSview, the whole page appears vertically, and the plot appears horizontally, which means that the plot is only partially visible (example here
2009 Jan 16
0
Barchart in lattice package: controlling order of bars in plot and color of a selected bar
Hi, I'm using the lattice function 'barchart' to make a series of 4 histograms. Currently, the y-axis values are graphed in order of the y-axis variable. I'd like to have the y-axis values sorted in ascending order of the x-axis values so that the longest bar horizontally is on top of the graph (in it's seciton) and the shortest bar is on the bottom. I can do this in
2005 Oct 23
1
Coloring leaves, twigs and labels in plot.dendrogram()
Core developers, I couldn't find any simple way to send a vector of colors to apply to each terminal in plot.dendrogram() or plot.hclust()---I asked R-help about it a few weeks ago and didn't get any response---so I hacked that functionality into the plot.dendrgram code (see below for hacked function plus examples).... Is there any chance this functionality could be added to the
2006 Sep 28
3
complex plots using layout()
Dear r-help, I am trying to plot several scatter plots with marginal histograms on one page. Ideally, a page is equally divided into 4 figure regions. Within each figure region, a scatter plot with marginal histograms will be plotted. I followed Dr. Paul Murrell's code released online to successfully plot the scatter plot with marginal histograms. The code applies "layout()" to
2010 Nov 15
1
plot.dendrogram() plot margins
Hello, Is it possible to remove those extra margins on the "sample" axis from plot.dendrogram: par(oma=c(0,0,0,0),mar=c(0,0,0,0)) ddr<-as.dendrogram(hclust(dist(matrix(sample(1:1000,200),nrow=100)))) stats:::plot.dendrogram(ddr,horiz=F,axes=F,yaxs="i",leaflab="none") vs. stats:::plot.dendrogram(ddr,horiz=T,axes=F,yaxs="i",leaflab="none")
2009 Mar 11
0
Working up examples of barplots with customized marginal items
Hello, everybody: I'm back to share a long piece of example code. Because I had trouble understanding the role of par() and margins when customizing barplots, I have struggled with this example. In case you are a student wanting to place legends or textual markers in the outer regions of a barplot, you might run these examples. There are a few little things I don't quite understand.
2004 May 19
7
Help with hclust() and plot()
Hi When I use plot(hclust(dist..)...)...) etc to create a dendrogram of a hierarchial cluster analysis, I end up with a vertical tree. What do I need to do to get a horizontal tree? Also, my users are used to seeing trees who's leaves all "end" at the same place (eg. Like in minitab). Is this possible in R? Thanks Mick Michael Watson Head of Informatics Institute for Animal
2017 Jun 17
1
Plot MArginal distribution in the correct place
Can you suggest a plot on the right side so that the right plot has the same units of left plot and reflect the counts of the number of time the values repeat, something like the empirical distribution? 2017-06-14 12:30 GMT+02:00 Jim Lemon <drjimlemon at gmail.com>: > Hi Pedro, > If you keep that same margins for the second plot: > > par(mar=c(10,0,6,6)) >
2004 Apr 15
1
tapply() and barplot() help files for 1.8.1
Hi, I've just upgraded to 1.9.0 and one of my Sweave files that produces a number of barplots in a standard manner now produces them in a different way. I have made a couple of small changes to my code to get the back the output I was getting before upgrading and now (mostly out of curiosity) would like to understand what has changed. I *think* I've tracked it down to tapply() and/or
2012 May 24
3
set tkscale by tkentry
Hi, I am working under Windows and I am using R2.11 I want to use tkscale in my GUI. As the interval is quite big, I can't set the scale to a certain specific value. Therefore I want to add tkentry to allow the user to set tkscale to a certain value. Here is the code library(tcltk) tt<-tktoplevel() tkpack(m1<-tkscale(tt,from=306870.00, to=3026741, label="alpha",
2006 Apr 17
0
autoscall the y-axis
Dear R users I need to auto scale the left y axis in the code below, so that when I scroll left or right the left y-axis scale changes to accumulate the range of the displayed data with in the max hight of the y-axis. also how can I make the crosshair horizontal since it is only vertical in this code. this code with a kind help from "Gregory (Greg) L. Snow Ph.D." just
2017 Jun 14
0
Plot MArginal distribution in the correct place
Hi Pedro, If you keep that same margins for the second plot: par(mar=c(10,0,6,6)) barplot(fhist$counts,axes=FALSE, space=0,horiz=TRUE,col="lightgray") it looks reasonably well aligned to me. Because you are plotting the counts of the values in Simulation, the ordinate (vertical axis) of the bar plot is in quite different units from that of the plot on the left side. Jim On Wed, Jun