similar to: S4 method dispatch

Displaying 20 results from an estimated 400 matches similar to: "S4 method dispatch"

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)
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,
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(),
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
2008 Jul 02
1
randomForest training error
While trying to train randomForest with my dataset, I am ending up with the following error Error in randomForest.default(datatrain, classtrain) : length of response must be the same as predictors My data looks like: A,B,C,D,Class 1,2,1,2,cl1 1,2,1,2,cl1 3,2,1,2,cl2 3,2,1,2,cl2 3,2,1,2,cl2 3,2,1,2,cl2 3,2,1,2,cl2 3,2,1,2,cl2 3,2,1,2,cl2 3,2,12,3,cl2 3,2,1,2,cl2 Actual dataset has around 4000
2008 Nov 26
5
could one scenario depend on another in cucumber?
I think it is a common test case you would meet. For example, you want to test a user registry scenario. You write: Scenario: User Registry When I dosth Then I dosth ... And now business has some changes. Register should have to activate his account by a secret code sent by mobile phone. So you need to write the other scenario: Scenario: User Registry and Account Activation By Mobile
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)
2005 Jul 27
1
unable to source a .R file using RJava
I am unable to source a ".R" file using RJava. I tried a couple of different tests: 1) using java and the evaluation method core dumps 2) using ./RJava --example --gui-none to invoke source core dumps. 3) The line of R works if I go directly thru R and not RJava. Version info and code are below. Any help would be appreciated. --Laura O'Brien Applications
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
2012 Jan 04
1
Is there a way to update a method on an existing Reference Class object?
Hi Being able to do object oriented programming in R is really good. I now started using the Reference Classes and really like it. Though, I have one problem: I cannot find a way to update a method on an existing object. The flexibility that scripting gives (really needed for interactive data analysis) is lost if everything have to be recalculated all the time. For example I would normally
2017 Jul 09
2
Histogram plots in Lattice with spatialgrid dataframe data
Hi all, I can not seem to get what I want using the Lattice package to generate an array of histograms of spatialgrid dataframe data. I can use the sp package and spplot to generate an array of maps that display an array of spatialgrid dataframe data -- that's good. I have:
2020 Jan 26
2
[RFC] Replacing inalloca with llvm.call.setup and preallocated
Hello all, A few years ago, I added the inalloca feature to LLVM IR so that Clang could be C++ ABI compatible with MSVC on 32-bit x86. The feature works, but there is room for improvement. I recently took the time to write up a design using token values that will hopefully be better named and easier to work with and around. For the technical details of the proposal, I've written up the RFC
2017 Jul 09
0
Histogram plots in Lattice with spatialgrid dataframe data
Hello all, After more digging I was able to find out how to do this. The answer came from an example here: https://stackoverflow.com/questions/3541713/how-to-plot-two-histograms-together-in-r yr_1997<-data.frame(bias=ann_bias$bias1997) yr_1998<-data.frame(bias=ann_bias$bias1998) yr_1999<-data.frame(bias=ann_bias$bias1999) yr_2000<-data.frame(bias=ann_bias$bias2000)
2011 Jan 05
1
Prediction error for Ordinary Kriging
Hi ALL, Can you please help me on how to determine the prediction error for ordinary kriging?Below are all the commands i used to generate the OK plot: rsa2 <- readShapeSpatial("residentialsa", CRS("+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs")) x2 <- readShapeSpatial("ptna2",
2010 Jan 26
2
No space left on device in one node
Hi! We operate a 2-node cluster running OCFS2 on top of DRBD. It shows about 4.3 GB free space on the OCFS2 filesystem using df on both nodes, but one node can't even write 10 MB: df (ouput identical on both the nodes) $ df -k /cluster Filesystem 1K-blocks Used Available Use% Mounted on /dev/drbd0 83883484 80071096 3812388 96% /cluster $ df -i /cluster
2017 Jul 10
1
Histogram plots in Lattice with spatialgrid dataframe data
Glad you found an answer, though it looks more self-educational than efficient (see suggestions below). In the future, follow the recommendations of the Posting Guide: use plain text, and provide a reproducible example. Some elaborations on what "reproducible" means are [1][2][3]. One issue here was that you did not include sample data to work with (I have assumed below that ann_bias has
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
2005 Apr 29
0
recording packet sent time
Hello I am writing a qdisc scheduler (called fb in the diagram) that does certain packet delaying and other stuff. (for egress traffic) root (htb/tbf) | --------------- cl1 cl2 | tbf -------- | | cl3 cl4 | | *fb* fifo Now I need to
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) ##########################
2007 Oct 10
1
silhouette: clustering labels have to be consecutive intergers starting from 1?
Hi list, When I was using 'silhouette' from the 'cluster' package to calculate clustering performances, R crashed. I traced the problem to the fact that my clustering labels only have 2's and 3's. when I replaced them with 1's and 2's, the problem was solved. Is the function purposely written in this way so when I have clustering labels, "2" and