similar to: Applying bagging in classifiers

Displaying 20 results from an estimated 1000 matches similar to: "Applying bagging in classifiers"

2013 Mar 23
1
LOOCV over SVM,KNN
Good afternoon. I would like to know if there is any function in R to do LOOCV with these classifiers: 1)SVM 2)Neural Networks 3)C4.5 ( J48) 4)KNN Thanks a lot! [[alternative HTML version deleted]]
2013 Apr 04
1
Extract the accuracy of 10-CV
Hello guys! I am working with some classifiers ( SVM,C4.5,RNA,etc) using 10-C.V. Once I have the model of each one, I make the validation of these models in one dataset. Then,with my model and the dataset, I extract a confusion matrix to know the capacity of prediction from the model. And finally, I extract the accuracy of this prediction based on the diagonal from the confusion matrix. The
2013 Mar 31
1
Creating new instances from original ones
I have a question about data mining. I have a dataset of 70 instances with 14 features that belong to 4 classes. As the number of each class is not enough to obtain a good accuracy using some classifiers( svm, rna, knn) I need to "oversampling" the number of instances of each class. I have heard that there is a method to do this. It consists in generating these new instances as follows:
2013 Mar 13
1
Accuracy of some classifiers
I am using machine learning for one researching. I am using some classifiers with 5-fold CV . I would like to know how it is possible to extract the accuracy, for example, for KNN,neural networks and J48, for each one of 5-fold because when I apply CV to my classifier, I obtain the "mean accuracy" of 5-fold but each accuracy/error of each fold is not returned. Any help is welcome and
2004 Feb 01
2
CART: rapart vs bagging
Hi, Is here anyone knows the difference between rapart and bagging when grow a CART tree? Thanks Qin
2004 Jul 26
1
do.call and double-colon access
Using R 2.0.0 of July 20 2004 train, test, and cl as defined in example(knn), we have > search() [1] ".GlobalEnv" "package:methods" "package:stats" "package:graphics" [5] "package:utils" "Autoloads" "package:base" > knn(train, test, cl, k=3) Error: couldn't find function "knn" >
2011 Sep 08
1
error in knn: too many ties in knn
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(10000,0,1)) > test <- matrix(nrow=10,ncol=2,data=rnorm(20,0,1)) > cl <- rep(c(0,1),2500) > knn(train,test,cl,1) [1] 1 1 0 0 1 0 1 1 0 1 Levels: 0 1 It
2007 Nov 27
1
Questions on RWeka classifiers?
Hi, I am using some classifiers in RWeka packages and met a couple problems. (1) J48 implements C45 classifier, the C45 should be able to handle missing values in both training set and test set. But I found the J48 classifier can not be evaluated on test set with missing values--it just ignore them. (2) The ensemble classifiers in RWeka such as bagging and boosting: there is a
2006 Jun 07
1
knn - 10 fold cross validation
Hi, I was trying to get the optimal 'k' for the knn. To do this I was using the following function : knn.cvk <- function(datmat, cl, k = 2:9) { datmatT <- (datmat) cv.err <- cl.pred <- c() for (i in k) { newpre <- as.vector(knn.cv(datmatT, cl, k = i)) cl.pred <- cbind(cl.pred, newpre) cv.err <- c(cv.err, sum(cl != newpre)) }
2010 Mar 09
1
create picture (k -the nearest neighbours)
Hi I want to create a nice picture about my result of k -the nearest neighbours algorithm. Here is my easy code: ################################# library(klaR) library(ipred) library(mlbench) data(PimaIndiansDiabetes2) dane=na.omit(PimaIndiansDiabetes2)[,c(2,5,9)] dane[,2]=log(dane[,2]) dane[,1:2]=scale(dane[,1:2]) zbior.uczacy=sample(1:nrow(dane),nrow(dane)/2,F)
2013 Apr 07
2
Working with createFolds
Hello! I have a question. I am working with createFolds: folds<- trainControl(method='cv', index=createFolds(data$Score,list = TRUE)) I need to iterate over folds to extract the indexes from each fold. For example, if I do folds$index$Fold01, it contains: 5 11 17 29 44 50 52 64 65 I need to iterate over each $Fold_i to extract the indexes, but I can't do it because I
2009 Apr 16
0
Problems with adabag
Hello, I'm trying to use adabag to make bagging and boosting with bagging() and adabost.M1(), respectively, but in both cases it produces an abnormal termination of R. My code is: bagging(I.NOSOCO~EDAD+SEXO+ESTANCIA+ADMISI?N+T.CIRUG?+DURACI?N+CONTAMIN +PROFILAX+E.PREOPE+V.PERIFE+V.CENTRA+S.VESICA+S.NASOGA+DREN.ABI+DREN.CER
2007 Apr 11
1
Function knn.dist from knnflex library
Hello, I am feeling that this question can have a very simple answer, but I can't find it. I need to use the function knn.dist from knnflex library. Whatever I try, I get the error: Error in as.vector.dist(x, "character") : unused argument(s) ("character") First example: > a<-NULL > a<-rbind(a,c(5.2,-8.1)) > a<-rbind(a,c(8.8,-16.1)) >
2011 Aug 31
8
!!!function to do the knn!!!
hi, r users i have a problem with KNN. i have 2 datasets, X0 and X1. >dim(X0) >1471*13 dim(X1) >5221*13 and for every instances in the dataset X1, i want to find the nearest neighbour(1nn) in the dataset X0. and i dont have the true classifications of dataset X1. but the function knn() need true classifications(cl) to do prediction. i just curious if there are some other function
2008 Oct 29
1
Help with impute.knn
ear all, This is my first time using this listserv and I am seeking help from the expert. OK, here is my question, I am trying to use impute.knn function in impute library and when I tested the sample code, I got the error as followingt: Here is the sample code: library(impute) data(khanmiss) khan.expr <- khanmiss[-1, -(1:2)] ## ## First example ## if(exists(".Random.seed"))
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
2009 Apr 25
1
Overlapping parameters "k" in different functions in "ipred"
Dear List, I have a question regarding "ipred" package. Under 10-fold cv, for different knn ( = 1,3,...25), I am getting same misclassification errors: ############################################# library(ipred) data(iris) cv.k = 10 ## 10-fold cross-validation bwpredict.knn <- function(object, newdata) predict.ipredknn(object, newdata, type="class") for (i in
2008 Sep 19
3
How to do knn regression?
Hello, I want to do regression or missing value imputation by knn. I searched r-help mailing list. This question was asked in 2005. ksmooth and loess were recommended. But my case is different. I have many predictors (p>20) and I really want try knn with a given k. ksmooth and loess use band width to define neighborhood size. This contrasts to knn's variable band width via fixing a
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
2002 Feb 05
2
Measures of agreement
Greetings. I've been experimenting with some algorithms for document classification (specifically, a Naive Bayes classifier and a kNN classifier) and I would now like to calculate some inter-rater reliability scores. I have the data in a PostgreSQL database, such that for each document, each measure (there are 9) has three variables: ap_(measure), nb_(measure), and knn_(measure). ap is me