similar to: R-alpha: ?bug in [.data.frame

Displaying 20 results from an estimated 10000 matches similar to: "R-alpha: ?bug in [.data.frame"

1997 Apr 08
1
R-alpha: rbind
rbind() does something strange to dimnames R : Copyright 1997, Robert Gentleman and Ross Ihaka Version 0.50 Beta (April 1, 1997) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type "license()" for details. > test1 <- data.frame(time= c(4, 3,1,1,2,2,3), + status=c(1,NA,1,0,1,1,0), + x= c(0,
1997 Apr 28
1
R-alpha: R-beta:matrix & vector multiplication.
Both of these used to work and seem useful and harmless: R> matrix(1,ncol=1)%*%c(1,2) Error in matrix(1, ncol = 1) %*% c(1, 2) : non-conformable arguments R> matrix(1,ncol=1)*(1:2) Error: dim<- length of dims do not match the length of object Thomas Lumley -----------------------------------------------------+------ Biostatistics : "Never attribute to malice what : Uni of
1997 Apr 28
1
R-alpha: R-beta:matrix & vector multiplication.
Both of these used to work and seem useful and harmless: R> matrix(1,ncol=1)%*%c(1,2) Error in matrix(1, ncol = 1) %*% c(1, 2) : non-conformable arguments R> matrix(1,ncol=1)*(1:2) Error: dim<- length of dims do not match the length of object Thomas Lumley -----------------------------------------------------+------ Biostatistics : "Never attribute to malice what : Uni of
1997 Oct 01
1
R-alpha: R-beta: hat
The hat() function, returning the diagonal of the hat matrix, currently works only on matrices and doesn't work with weights. Could we make it return lm.influence(x)$hat when inherits(x,"lm")? Thomas Lumley ------------------------------------------------------+------ Biostatistics : "Never attribute to malice what : Uni of Washington : can be adequately explained by :
1997 Apr 01
0
R-beta: Re: R-alpha: My two problems
On Tue, 1 Apr 1997, Jim Lindsey wrote: > Neither setting environment nor command > line change memory size as given by gc(). However, if I give too small > or too large a value on the command line, it tells me that it is > invalid and is ignoring it!?? I repeat that when I recompiled changing > the default size, gc() changed its values. Am I misunderstanding > something? I
1998 Apr 09
1
0-extent matrices?
Is there a good reason not to allow matrix extents to be zero? I have been writing a function which fits glms under certain linear constraints. I fit the model with a reduced set of variables and then transform back to the original set. This involves operating on submatrices of the covariance matrix and subsets of the coefficients. Sometimes these subsets are empty. A zero-length subset of the
1997 Aug 21
0
R-beta: problem with gee() with singletons
A bug (misfeature) has been found in the S gee library (and thus in the R gee library). The problem, which is shared by nearly all gee implementations, involves the calculation of working correlations when some clusters have only one observation. For compatibility reasons nearly everyone uses the computing formula from the first SAS macro by Karim, rather than the formula from the original GEE
1997 Oct 08
0
R-beta: calling R from FORTRAN
There was a question earlier today, on either r-help or r-devel, about calling R code from FORTRAN (I deleted it accidentally, so I don't know which list it belonged to). Anyway, there is a workaround to call R functions from FORTRAN which is used in the "integrate" library. It was invented for S by Mike Meyer. The FORTRAN code needs to be written to call a fixed C function and
1997 Jun 25
3
R-alpha: lbeta, ctrl-C and crashes
1. lbeta and beta do not work properly: lbeta returns its first argument and beta gives the lbeta result. In names.c lines 245-6, the codes for these should be 2 and 3 instead of 1 and 2 2. crtl-C does not work (except the first time) on Red Hat elf Linux (which has many many other problems as well) nor on the previous version of Linux for Amiga. It worked on Slackware aout Linux and now works
1997 Jun 25
3
R-alpha: lbeta, ctrl-C and crashes
1. lbeta and beta do not work properly: lbeta returns its first argument and beta gives the lbeta result. In names.c lines 245-6, the codes for these should be 2 and 3 instead of 1 and 2 2. crtl-C does not work (except the first time) on Red Hat elf Linux (which has many many other problems as well) nor on the previous version of Linux for Amiga. It worked on Slackware aout Linux and now works
1997 Aug 20
1
R-alpha: R-0.50-a3: [logical, drop = FALSE] -- bug in R (and S-plus)
This is a bug both in R and S-plus (in R it's "worse"), I think. Look at this : ma <- cbind(1,1:8); logi <- rep(c(T,F),4) ma[logi,] ##> [,1] [,2] ##> [1,] 1 1 ##> [2,] 1 3 ##> [3,] 1 5 ##> [4,] 1 7 ##-- now the same with [ , drop = FALSE] ## R (-0.50-a3) : ma[logi, drop = F] ##>> Error: invalid subscript type ##
1997 Jun 27
1
R-alpha: NA in data frame not detected
NA's in a data frame are not handled properly, if the data frame was read in using read.table (but I'm not sure if that is the reason of the problems): (I'm using Debian Linux 1.3) If I read the file *************** 1 2 2 3 3 4 4 5 ? 6 6 7 7 8 8 9 *************** into R using read.table I run into troubles: R : Copyright 1997, Robert Gentleman and Ross Ihaka Version 0.49 Beta
1997 Jun 20
2
R-beta: purpose of n in identify() function?
I think I am misunderstanding something about the identify() function. if we have an example such as this: > x_1:10 > y_1:10 > plot(x,y) > identify(x,y, n=1) [1] 2 3 > I clicked on two points and identify() returned both of them (2 and 3). The manual says n is the maximum number of points to be identified. If I specify n=1, should identify() return a single value?
1997 Sep 22
1
R-alpha: x[NA]
Just curious. Current logic in both R and Splus has > (1:3)[c(T,F,NA)] [1] 1 NA Does anyone know *why*? It makes sense for integer indexing, but for logicals it seems to have some strange consequences - if you divide a dataframe according to some criterion, you get as many NA-filled records as there are missing values of the criterion added to *both* the group that satisfies the criterion
1998 Apr 17
2
R-beta: lmsreg
Does R have a function like the S(plus) function, lmsreg, Least Median of Squares Regression? I am using R-0.61. Thank you, Mike Fleming mfleming at nass.usda.gov -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or
1998 Apr 17
2
R-beta: lmsreg
Does R have a function like the S(plus) function, lmsreg, Least Median of Squares Regression? I am using R-0.61. Thank you, Mike Fleming mfleming at nass.usda.gov -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or
1998 Feb 26
2
R-beta: question on dyn.loaded code
Hi, when designing libraries for R, is it possible to call C/Fortran subroutines from other dynamically loaded code? The following example crashes R: ********* fn1.c ***************** void twice(int *i) { *i = 2 * *i; } ********************************* ********* fn2.c ***************** extern int twice(int *i); void negtwice(int *i) { *i = -1 * twice(i); }
1998 Feb 26
2
R-beta: question on dyn.loaded code
Hi, when designing libraries for R, is it possible to call C/Fortran subroutines from other dynamically loaded code? The following example crashes R: ********* fn1.c ***************** void twice(int *i) { *i = 2 * *i; } ********************************* ********* fn2.c ***************** extern int twice(int *i); void negtwice(int *i) { *i = -1 * twice(i); }
1997 Jun 23
1
R-alpha: comparing alpha and numeric
Is this behavior correct? (R 0.49 on SunOS 4.1.4) > "a">1 TRUE > "a"<1 FALSE > "a"==1 FALSE > "a">2 TRUE > "a"<2 FALSE (I know, this is like the old joke: "Doctor, it hurts when I do this." "Well, don't do that!" But it might be useful to have this caught by an error or warning message
1997 Apr 15
1
R-alpha: Bug & Patch in dbeta.c (0.50 - PreR 7)
dbeta(1, a,b) would return 1 instead of 0. Here is the patch for ..../src/math/dbeta.c : --- dbeta.c~ Sun Nov 24 23:43:10 1996 +++ dbeta.c Tue Apr 15 21:25:30 1997 @@ -23,9 +23,7 @@ { if (a <= 0.0 || b <= 0.0) DOMAIN_ERROR; - if (x <= 0) + if (x <= 0 || x >= 1.0) return 0.0; - if (x >= 1.0) - return 1.0; return MATH_CHECK(pow(x, a - 1) * pow(1.0 - x, b - 1.0) /