Re: [R] error in knn: too many ties in knn

2011-09-10 Thread Uwe Ligges
On 08.09.2011 14:19, Максим Иванов wrote: Hello. I found the behavior of knn( http://stat.ethz.ch/R-manual/R-devel/library/class/html/knn.html) function looking very strange. Consider the toy example. library(class) train- matrix(nrow=5000,ncol=2,data=rnorm(1,0,1)) test-

[R] error in knn: too many ties in knn

2011-09-08 Thread Максим Иванов
Hello. I found the behavior of knn( http://stat.ethz.ch/R-manual/R-devel/library/class/html/knn.html) function looking very strange. Consider the toy example. library(class) train - matrix(nrow=5000,ncol=2,data=rnorm(1,0,1)) test - matrix(nrow=10,ncol=2,data=rnorm(20,0,1)) cl -

[R] Error regarding knn imputation

2010-03-29 Thread ankhee dutta
Hi Everybody, I am having problem while running a code in R related to knn imputation of my matrix. The code i am using is as follows: t - read.table(file=/home/ankhee/Desktop/Different_datasets/KADOSH_2005, check.names=FALSE, row.names=1,colClasses=NA, sep=\t,header=T) r-as.matrix(t)

Re: [R] Error with KNN

2010-02-23 Thread Uwe Ligges
. Best wishes, Uwe Many thanks, Nancy Date: Mon, 22 Feb 2010 17:19:48 +0100 From: lig...@statistik.tu-dortmund.de To: nancyada...@hotmail.com CC: r-help@r-project.org Subject: Re: [R] Error with KNN On 20.02.2010 19:10, Nancy Adam wrote: Hi all I receive this error message: “Error

Re: [R] Error with KNN

2010-02-22 Thread Uwe Ligges
On 20.02.2010 19:10, Nancy Adam wrote: Hi all I receive this error message: “Error in mymodel$MSE : $ operator is invalid for atomic vectors” When I use KNN. This is the code: library(e1071) train- rbind(iris3[,,1], iris3[,,2], iris3[,,3]) cl- factor(c(rep(s,50), rep(c,50), rep(v,50)))

Re: [R] Error with KNN

2010-02-22 Thread Nancy Adam
To: nancyada...@hotmail.com CC: r-help@r-project.org Subject: Re: [R] Error with KNN On 20.02.2010 19:10, Nancy Adam wrote: Hi all I receive this error message: “Error in mymodel$MSE : $ operator is invalid for atomic vectors” When I use KNN. This is the code: library(e1071

[R] Error with KNN

2010-02-20 Thread Nancy Adam
Hi all I receive this error message: “Error in mymodel$MSE : $ operator is invalid for atomic vectors” When I use KNN. This is the code: library(e1071) train - rbind(iris3[,,1], iris3[,,2], iris3[,,3]) cl - factor(c(rep(s,50), rep(c,50), rep(v,50))) knn.cv(train, cl, k = 3, prob =