Displaying 20 results from an estimated 3000 matches similar to: "RE: cut.dendrogram (PR#1552)"
2002 May 15
0
RE: cut.dendrogram (PR#1552)
>>>>> "MM" == Martin Maechler <maechler@stat.math.ethz.ch> writes:
>>>>> "MikG" == M GRUM <M.GRUM@CGIAR.ORG> writes:
MikG> I'm resending this bug report with a new example. As
MikG> seen below, cut.dendrogram gives an error message for
MikG> some heights, but not for others and with some
MikG> datasets
2002 May 14
0
RE: cut.dendrogram (PR#1552)
I'm resending this bug report with a new example. As seen below,
cut.dendrogram gives an error message for some heights, but not for others
and with some datasets adn not others. I can't see why.
Last time I unwittingly sent my message with HTML formatting. This time I'm
travelling and using an e-mail system that I am unfamiliar with. As far as
I can see, I am not using HTML.
2003 Aug 04
1
hclust() and agnes() method="average" divergence (PR#3648)
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_000_01C35A53.75780090
Content-Type: text/plain;
charset="iso-8859-1"
Anyone have a clue why hclust() and agnes() produce different results in the
example below when both use method="average"?? I'm not able to reproduce
2001 Aug 09
1
Mixed mode import problem
First question:
I have an Excel file with both character and numeric variables that I want
to import to a data.frame, so I've saved the data to a tab-delimited text
file.
read.table :
* Won't identify the mode of my character variables, as some of them
contain only numbers and none of them are surrounded by quotes,
* Won't allow me to specify the mode of my variables,
* Doesn't
2001 Aug 13
3
subset syntax
Can anyone tell me what's wrong with this command??
xx<-subset(x,LOCAL.NAME==c("Chifumbata","Chikota"),select=c(13,16,19,23,26,2
9,30,33:48))
Warning message:
longer object length
is not a multiple of shorter object length in: LOCAL.NAME ==
c("Chifumbata", "Chikota")
both of the following commands work fine
2002 Jan 08
3
colour coding and different point types in a plot
I'm trying to plot four different sorghum types on a plot using a different
colour/symbol combination for each sorghum type (TYPBOTA in the script
below). What am I doing wrong?:
plot(xx$LATITUDE,xx$SFD1,
points(xx$SFD1,xx$LATITUDE,
col=1:4[codes(xx$TYPBOTA)],pch=c(4,3,1,2)[codes(xx$TYPBOTA)])
grid()
I get the following error message
Error in 1:4[codes(xx$TYPBOTA)] : NA/NaN argument
2002 Jan 08
6
Subsets without NA
Is there a way of removing all rows with missing values from a data frame?
I usually use
subset(x, var1!="NA")
and repeat for each variable. It would be nice to be able to do it in one
fell swoop. Also, surprisingly, it doesn't always work. Sometimes I'm left
with an empty set even though not all rows have missing values for the
variable.
Cheers,
mikkel
Mikkel Grum,
2003 Sep 02
1
Plotting dates
I'm trying to plot observations against observation dates and getting julian
dates along the x-axis:
library(date)
Week<-as.date(c("05/02/03","05/09/03","05/16/03","05/23/03","05/30/03","06/0
7/03","06/14/03"))
Leafminers<-c(0,2,5,10,4,6,5)
Diglyphus<-c(0,0,4,5,7,3,1)
LeafDig<-cbind(Week,Leafminers,Diglyphus)
2001 Aug 21
4
looking for a smarter way
I have two problems where I've come up with some code that will do the
analysis that I want, but it looks pretty clumsy. In the first case, I
calculate the variance on five different columns for each of 14 clusters and
get them into one matrix. I get the job done, but I would have thought that
it could be done in one or two lines, not six, and be generalized so that it
didn't matter how
2002 May 14
1
cutree() and horizontal dendrograms
When I use the function cutree(), the numbers of the clusters are not in the
same order as the plotted dendrogram. Is there any way of sorting them so
that they match the tree?
Is it possible to plot a dendrogram horizontally, preferably with the
branches to the right? This would enable some practical composite plots,
e.g. labels that were an entire table with several columns of information,
or
2003 Jan 07
2
Extracting means for given strata from dissimilarity object
Is there a way of extracting mean distance or dissimilarity for a given
strata from a 'dist' or 'dissimilarity' object, e.g. extract mean distances
for each species in Anderson's iris data?
data(iris)
iris.dist<-dist(iris[,1:4])
then what?
Mikkel Grum, PhD
Genetic Diversity Scientist
International Plant Genetic Resources Institute (IPGRI)
Sub-Saharan Africa Group
***
2003 Aug 18
0
displaying pruned clusters
Any idea why clusters five and six fall off the scale in the following?
library(cluster)
library(maptree)
data(flower)
dfl2<-daisy(flower,type=list(asymm=c(1,3),ordratio=7))
hdfl2<-hclust(dfl2)
prune.dfl2<-prune.clust(hdfl2,k=6)
plot(prune.dfl2)
Of course the following will display all six clusters, but without a scale:
draw.tree(prune.dfl2)
Best wishes,
Mikkel
Mikkel Grum
2012 Aug 12
0
Different cluster orderings from cutree() and cut.dendrogram()
Hi!
I just discovered that cutree() and cut.dendrogram() do not assign the
same cluster numberings when called on the same tree. More specifically,
cutree() assigns cluster numbers by order of appearance in the data,
while cut.dendrogram() sorts clusters by height (see example below). I
guess this is for historical reasons?
I'm hit by this difference when I want to get a vector of cluster
2007 Oct 26
2
cut.dendrogram and cutree
Hi!
In the example:
hc <- hclust(dist(USArrests), "ave")
dend1 <- as.dendrogram(hc)
dend2 <- cut(dend1, h=70)
Do the branches "Branch 1", "Branch 2", "Branch 2"...in dend2$upper
str(dend2$upper)
--[dendrogram w/ 2 branches and 4 members at h = 152]
|--[dendrogram w/ 2 branches and 2 members at h = 77.6]
| |--leaf "Branch 1" (h=
2002 Jun 07
1
Bug list summary (automatic post)
=================================================
This is an automated summary of the status of the R-bugs
repository.
Note that this may be neither complete nor perfectly
correct at any given instance: Not all bugs are reported,
and some reported bugs may have been fixed, but the
repository not yet updated.
Some bug fixes are difficult to verify because they pertain
to specific hardware or
2004 Jul 21
2
Cutting heatmap dendrogram
Hello,
I've been clustering my data using hclust and cutting the resulting tree
with cutree. Separately, I visualize the clusterings with heatmap. Is it
possible to have the dendrogram on the heatmap reflect the cutree results?
That is, instead of having one large dendrogram, it would have 4 or 25 in
the example below. Any guidance on if that's possible or not, and what
kinds of
2008 Oct 13
1
cut.Date problem when starting on first day of week (PR#13159)
Apparently any (?) call of the form
cut(date,"weeks")
where the date *begins the week*, gives the error
Error in 1:(1 + max(which(breaks < maxx))) :
result would be too long a vector
In addition: Warning message:
In max(which(breaks < maxx)) :
no non-missing arguments to max; returning -Inf
To my surprise, this was first reported as a problem in 2006 (!)
(version 2.3.1
2012 Oct 24
0
recursive function on a structured list of lists (dendrogram)
Dear all,
I have been trying the following without avail and would be very grateful for any help. From a dendrogram (recursive list of lists with some structure), I would like to obtain some information of the component lists and of the enclosing list at the same time. In dendrogram-speech I basically would like the label of the leaf and the height of the enclosing branch.
A dendrogram example
2012 Jun 28
0
neatmap - draw.dendrogram - help!
Hi all,
I'm having a problem where by I'm trying to use the NeatMap draw.dendrogram
function as it is more versatile in placement/direction of dendrograms,
instead of the limited plot function.
Using plot I can get my dendrograms to display the species name for each
leaf of the tree. But I cannot figure out how to make this happen using
draw.dendrogram..
genetic<-
2013 Jan 16
1
dendrogram stops!
Dear I am using the 'as.dendrogram' function from the 'stats' library to convert from an hclust object to a dendrogram with a dataset of size
~30000 (an example code is below). I need the dendrogram structure to
use the "dendrapply" and "attributes" functions and to access the child
nodes, I do not need any of the plot properties.
The problem is that it