similar to: Cluster analysis: hclust manipulation possible?

Displaying 20 results from an estimated 2000 matches similar to: "Cluster analysis: hclust manipulation possible?"

2010 Jul 20
1
p-values pvclust maximum distance measure
Hi, I am new to clustering and was wondering why pvclust using "maximum" as distance measure nearly always results in p-values above 95%. I wrote an example programme which demonstrates this effect. I uploaded a PDF showing the results Here is the code which produces the PDF file: ------------------------------------------------------------------------------------- s <-
2009 Jan 27
1
Plotmath and line breaks in long annotations for plots
I'm trying to combine multi-line text and math annotations on a plot and am not having much luck. I looked at various suggestions in the archives, but I cannot coerce any of them to do what I want. I'm beginning (finally?!) to think that there is an entirely better approach than the one I have tried. The essential problem is that line breaks (\n) don't seem to behave the way I
2008 Jul 03
1
randomForest.error: length of response must be the same as predictors
My data looks like: A,B,C,D,Class 1,2,0,2,cl1 1,5,1,9,cl1 3,2,1,2,cl2 7,2,1,2,cl2 2,2,1,2,cl2 1,2,1,5,cl2 0,2,1,2,cl2 4,2,1,2,cl2 3,5,1,2,cl2 3,2,12,3,cl2 3,2,4,2,cl2 **The steps followed are: trainfile <- read.csv("TrainFile",head=TRUE) datatrain <- subset(trainfile,select=c(-Class)) classtrain <- (subset(trainfile,select=Class)) rf <- randomForest(datatrain, classtrain)
2013 Jun 18
1
hist function in a for loop
Dear all, I need to create a for-loop in which I can compute multiple histograms My code is the following : #singlefile includes huge csv file #I want to specify the binsize #I would like to compute in the for -loop the histograms numfiles <- length(singlefile) for (i in 1 :51) { binsize <- -20 :20/2 hist(singlefile(singlefile$GVC[singlefile$new_id==i]], break=seq(),
2006 Aug 10
1
How to speed up nested for loop computations
Dear all, here is the result of R.Version(): > R.Version() $platform [1] "powerpc-apple-darwin8.6.0" $arch [1] "powerpc" $os [1] "darwin8.6.0" $system [1] "powerpc, darwin8.6.0" $status [1] "" $major [1] "2" $minor [1] "3.1" $year [1] "2006" $month [1] "06" $day [1] "01" $`svn rev`
2005 Jul 06
1
Error message NA/NaN/Inf in foreign function call (arg 6) when using knn()
I am trying to use knn to do a nearest neighbor classification. I tried using my dataset and got an error message so I used a simple example to try and understand what I was doing wrong and got the same message. Here is what I typed into R: try [,1] [,2] [,3] [,4] r "A" "A" "T" "G" r "A" "A" "T" "G" f
2010 Jun 30
1
parameterization of glm nested design
Dear R community, I am new to R, a reforming SAS user :) I am running R 2.10.1 on a Windows XP machine. I would like to write linear functions of my coefficient parameter estimates from a glm, but am having a difficult time understanding the parameterization R uses. In the toy example below I am running a glm on binomial data, with clones and lines within clones as fixed effects, each with 6
2011 Sep 14
1
S4 method dispatch
List, In order to get rid of some old, unreadable S3 code in package sp, I'm trying to rewrite things using S4 methods. Somewhere I fail, and I cannot sort out why. In order to isolate the problem, I created two functions, doNothing<- and dosth, and both should do nothing. The issue is that in most cases they do nothing, but in some cases dosth(obj) changes the class of obj and breaks with
2011 Jun 21
1
plot error bars on skyline plot
Hi, I have generated a skyline plot of a tree in newick format using "ape". How can I plot the error bars for this graph? I only have the the tree data. un<-"((((8.1:0, 20.1:0):0, 6.1:3):123, (((((35.1:0, (22.1:0, (43.1:1, 29.1:0):0):0):4, 25.1:6):0, ((42.1:0, 21.1:0):3, (39.1:0, 2.1:0):3):1):8, (3.1:0, 7.1:0):8):48, (((((15.1:0, 14.1:0):0, 11.1:0):0, 37.1:0):0,
2004 May 05
1
Segfault from knn.cv in class package (PR#6856)
The function knn.cv in the class package doesn't have error checking to ensure that the length of the classlabel argument is equal to the number of rows in the test set. If the classlabel is short, the result is often a segfault. > library(class) > dat <- matrix(rnorm(1000), nrow=10) > cl <- c(rep(1,5), rep(2,5)) > cl2 <- c(rep(1,5), rep(2,4)) > knn.cv(dat, cl) [1] 2
2008 Mar 18
3
Partition data into clusters
Greetings R-users, I have been using the fpc package in R to cluster my data. Speficically I am using kmeansruns clustering. I would like to know how I use R to partition data into clusters. What I am doing is as follows. # Use csv file as input ##################### wholeset = read.csv("Spellman800genesImputed.csv") # exclude first col (gene names) ##########################
2008 May 28
1
heatmap-changing column or row names
Dear R Community, I am trying to create an heatmap for the following set of data: ##example of data matrix o4 V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 V11 V12 V13 V14 V15 V16 V17 V18 green 27 28 29 29 28 28 26 25 25 23 23 22 22 21 21 22 22 22 yellow 6 8 8 7 7 7 6 6 6 7 7 7 6 6 6 6 6 5 red 15 15 15 15 15 15 14 13 12 11 12 10 9 8 7 6 8 9 pink
2013 Feb 01
29
cumulative sum by group and under some criteria
Thank you very much for your reply. Your code work well with this example. I modified a little to fit my real data, I got an error massage. Error in split.default(x = seq_len(nrow(x)), f = f, drop = drop, ...) : Group length is 0 but data length > 0 On Thu, Jan 31, 2013 at 12:21 PM, arun kirshna [via R] < ml-node+s789695n4657196h87@n4.nabble.com> wrote: > Hi, > Try this: >
2011 May 19
3
problem with optim()
Dear R-users, I would like to maximize the function g above which depends on 4 parameters (2 vectors, 1 real number, and 1 matrix) using optim() and BFGS method. Here is my code: # fonction to maximize g=function(x) { x1 = x[1:ncol(X)] x2 = x[(ncol(X)+1)] x3 = matrix(x[(ncol(X)+2):(ncol(X)+1+ncol(X)*ncol(Y))],nrow=ncol(X),ncol=ncol(Y)) x4 = x[(ncol(X)+1+ncol(X)*ncol(Y)+1):length(x)]
2013 Mar 05
1
Reading Wyoming radiosonde data files with RadioSonde package
Hi, I need to do some analysis on historic daily radiosonde data I download from the Wyoming Univ. web page ( http://weather.uwyo.edu/upperair/sounding.html). I am trying to use the RadioSonde package (V 1.3), but the format of the files from Wyoming don't match what RadioSonde is expecting. Has anyone used the Radiosonde package on the Wyoming data? Here is a sample of the Wyoming file
2007 Oct 03
1
inverse of matrix made by low.tri function
Hi all, I am using R trying to get a inverse matrix of (X^T)X , but I keep getting the error message like: no b argument and no default value for sprintf(gettext(fmt, domain = domain), ...) . -------------------------------------------------------------------------------------------- # my code X<-Matrix(rep(1,500),100,5) X[lower.tri(X)]<-1-10^-7 XtX<- t(X)%*% X XtXu<-lu(XtX)
2018 Dec 18
2
should we do this time-consuming transform in InstCombine?
Hi, There is an opportunity in instCombine for following instruction pattern: %mul = mul nsw i32 %b, %a %cmp = icmp sgt i32 %mul, -1 %sub = sub i32 0, %a %mul2 = mul nsw i32 %sub, %b %cond = select i1 %cmp, i32 %mul, i32 %mul2 Source code for above pattern: return (a*b) >=0 ? (a*b) : -a*b; Currently, llvm(-O3) can not recognize this as abs(a*b). I initially think we could do this in
2013 Jun 10
4
Combining CSV data
Hello R community, I am trying to combine two CSV files that look like this: File A Row_ID_CR, Data1, Data2, Data3 1, aa, bb, cc 2, dd, ee, ff File B Row_ID_N, Src_Row_ID, DataN1 1a, 1, This is comment 1 2a, 1, This is comment 2 3a,
2002 May 02
2
a question
Hi, I have a program written in R which is good on the version 1.2, but for the fallowing versions of R, an error always is at the same place. That is at the level of the fallowing line: Sur<- getInitial(res2[m:M,2]~SSasymp(res2[m:M,1],Asymp,resp0,lrc),data=res2) Error in eval(expr,envir,enclos):numeric envir arg not of length one I don't know at all this langage for the instant.
2004 Jun 01
1
swapping with data.frame
Hi there, I have some data which are convenient to enter as lists. For example: t1<-list(fname="animal1",testname="hyla",dspkr="left",res1=39.7,res2=15.0) t2<-list(fname="animal1",testname="bufo",dspkr="left",res1=14.4,res2=56.1)