similar to: Help with the Error Message in R "Error in 1:nchid : result would be too long a vector"

Displaying 20 results from an estimated 6000 matches similar to: "Help with the Error Message in R "Error in 1:nchid : result would be too long a vector""

2016 Apr 14
4
Bug in by() function which works for some FUN argument and does not work for others
Dear Sirs, I am Professor at Indira Gandhi Krishi Vishwavidyalaya, Raipur, Chhattisgarh, India. While taking classes, I found the *by() *function producing following error when I use FUN=mean or median and some other functions, however, FUN=summary works. Given below is the output of the example I used on a built-in dataset "mtcars", along with error message reproduced herewith: >
2009 Sep 29
1
Summary
My data is called xc and has more than 15 variables. When I used summary(xc) it gave me the detail description of each variable. Summary(xc) Y1 x1 x2 x3 .. Min. :0.0000 Min. : 1.000 Min. : 1.000 Min. : 1.000 1st Qu. :0.0000 1st Qu.: 1.000 1st Qu.: 1.000 1st Qu.: 2.000 Median :1.0000 Median : 1.000
2016 Apr 14
0
Bug in by() function which works for some FUN argument and does not work for others
I think you are not using the best function for what your intentions are. Try: > by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) : 0 mpg cyl disp hp drat wt qsec vs 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 18.1831579 0.3684211 am gear carb 0.0000000
2016 Apr 15
4
Bug in by() function which works for some FUN argument and does not work for others
Dear All, Thanks for your help. However, I would like to draw your attention to the following: Actually, I was replicating the Example 2.3, using the dataset "brainsize.txt" given in Section 2.3.3 ("Summarize by group") at page 55, of a famous book "R by Example" written by "Jim Albert and Maria Rizzo" published in Springers (2012) in a Use R! Series. The
2016 Apr 16
2
Bug in by() function which works for some FUN argument and does not work for others
Dear All, I have got your core message, that it is my responsibility to determine whether any particular function in my version of R satisfies the language requirements at the time of your use. Jim Albert and Maria Rizzo must have used their code, which was permitted in the R-code of their time (2012). Therefore, I have now modified my R-code, as per R-3..2.4 version, according to my requirement
2016 Apr 15
0
Bug in by() function which works for some FUN argument and does not work for others
> On Apr 15, 2016, at 1:16 AM, Akhilesh Singh <akhileshsingh.igkv at gmail.com> wrote: > > Dear All, > > Thanks for your help. However, I would like to draw your attention to the > following: > > Actually, I was replicating the Example 2.3, using the dataset > "brainsize.txt" given in Section 2.3.3 ("Summarize by group") at page 55, > of a
2016 Apr 17
0
Bug in by() function which works for some FUN argument and does not work for others
> On Apr 16, 2016, at 2:03 AM, Akhilesh Singh <akhileshsingh.igkv at gmail.com> wrote: > > Dear All, > > I have got your core message, that it is my responsibility to determine whether any particular function in my version of R satisfies the language requirements at the time of your use. Jim Albert and Maria Rizzo must have used their code, which was permitted in the R-code
2012 Jun 13
1
How to calculate the statistcs for extracted region?
I have a binary file(a) with size of (360 720 )for the globe.I wrote the code given below to read and extract an area (south america)from that file. when I use summary for the whole file I got: summary(a, na.rm=FALSE) Min. 1st Qu. Median Mean 3rd Qu. Max. NA's 0.00 1.00 3.00 4.15 7.00 20.00 200083 . But when I used summary for the region(b) which I extracted, I got
2011 Jan 09
1
Operating on count lists of non-equal lengths
This is my first post to R-help and I look forward receiving some advice for a novice like me... I?ve got a simple repeated (4 periods so far) 10-question survey data that is very easy to work on Excel. However, I?d like to move the compilation to R but I?m having some trouble operating on count list data in a neat way. The data C > str(C) 'data.frame': 551 obs. of 13
2020 Oct 01
0
Help with the Error Message in R "Error in 1:nchid : result would be too long a vector"
Hello Rui, Thanks a lot for your response. But, I will surely say that the data I attached is in long format as it has 18 rows (3 alternatives*3 questions* 2 individuals). Had it been a wide format data it would have had 6 rows (3 questions* 2 individuals). But, anyway thanks. Best, Rahul On Wed, Sep 23, 2020 at 3:23 AM Rui Barradas <ruipbarradas at sapo.pt> wrote: > > Hello, >
2011 Jul 25
1
lme convergence error
Hello, I am working from a linux 64 machine on a server with R-2.12 (I can't update to 2.13). I am iterating through many linear mixed models for longitudinal data and I occasionally receive the following convergence error: > BI.lme <- lme(cd4 ~ time + genBI + genBI:time + C1 + C2 + C11 + C12, random =~ 1 + time | IID, data = d) Error in lme.formula(cd4 ~ time + genBI + genBI:time +
2008 Nov 20
5
summary statistics into table/data base, many factors to analyse
Dear list, I reduced my data to the following: x <- c(1,4,2,6,8,3,4,2,4,5,1,3) y <- as.factor(c(2,2,1,1,1,2,2,1,1,2,1,2)) z <- as.factor(c(1,2,2,1,1,2,2,3,3,3,3,3)) I can produce the statistical summary just fine. s1 <- tapply(x, y, summary) d1 <- tapply(x, y, sd) s2 <- tapply(x, z, summary) d2 <- tapply(x, z, sd) First thing: I have 100 plus factors to analyse. Theirs
2011 Sep 07
1
randomForest memory footprint
Hello, I am attempting to train a random forest model using the randomForest package on 500,000 rows and 8 columns (7 predictors, 1 response). The data set is the first block of data from the UCI Machine Learning Repo dataset "Record Linkage Comparison Patterns" with the slight modification that I dropped two columns with lots of NA's and I used knn imputation to fill in other gaps.
2012 Oct 10
2
Summary using by() returns character arrays in a list
I use by() to generate a summary statistics like so: Lbys <- by(dat[Nidx], dat$LipTest, summary) where Nidx is an index vector with names picking out the columns in the data frame dat. This returns a list of character arrays (see below for str() output) where the columns are named correctly but the rownames are empty strings and the values are strings prepended with the summary
2006 Dec 14
5
Nicely formatted tables
If I use latex(summary(X)) where X is a data frame with four variables I get something like Rainfall Education Popden Nonwhite Min. :10.00 Min. : 9.00 Min. :1441 Min. : 0.80 1st Qu.:32.75 1st Qu.:10.40 1st Qu.:3104 1st Qu.: 4.95 Median :38.00 Median :11.05 Median :3567 Median :10.40 Mean :37.37 Mean :10.97 Mean :3866
2013 Jul 30
1
Ayuda
Hola colegas: He estado usando R Studo para obtener unos reportes que espero me ayuden a comprender un ejemplo que estoy tomando de la red. Usando sink("Tabla.txt") , al pedir summay(n), obtengo: sr tl 1 : 1 1: 4 10 : 1 2:13 18 : 1 3:10 30 : 1 4: 4 47 : 1 7: 9 67 : 1 (Other):34 d Min. : 1.000 1st Qu.: 2.000 Median : 5.000
2001 Feb 28
1
print()
Hi, I've two questions. Please help me. Thanks! --- Question (1) --- When I type: print("School Name") the output is: [1] "School Name" How to get rid of the '[1]' and the double quotes "" and make the output like this: School Name --- Question (2) --- I got the following output by typing "summary(data)". dstuser dstmethod
2005 May 31
1
apply the function "factor" to multiple columns
I have a case where I would like to change multiple columns containing numbers to factors. I can change each column one at a time as in: TEMP.FACT$EXPOS01<-factor(TEMP.FACT$EXPOS01,levels=c(1,2,3),labels=c("No ne","Low Impact","MedHigh Imp")) TEMP.FACT$EXPOS02<-factor(TEMP.FACT$EXPOS02,levels=c(1,2,3),labels=c("No ne","Low
2010 Jan 07
1
Drop a part of an array\list\vector?
I did have a verbose description of why but rather then make everyone's eyes bleed with useless details I ask the following :) To make a long story short: How can I make newmcReg[[i]]["PreIO308"] go away in the following list... er vector... no wait array.... dataframe.... awww crap... summary(newmcReg[[i]]) UNITBUILD UNITDB ITBUILD ITDB Mode :logical
2007 May 27
1
Problem while working with SPSS data
Dear all R users, I got a strange problem while working with SPSS data : I wrote following : library(foreign) data.original = as.data.frame(read.spss(file="c:/Program Files/SPSS/Employee data.sav")) data = as.data.frame(cbind(data.original$MINORITY, data.original$EDUC, data.original$PREVEXP, data.original$JOBCAT, data.original$GENDER)) colnames(data) = c('MINORITY',