Displaying 5 results from an estimated 5 matches for "lapplyby".
Did you mean:
lapply
2009 Jun 09
1
how to use "lapplyBy" function of "doBy" package
...up mean of which the "NA" is
belonging to. For example, substitute the first record of traits "NA" by the
mean of "BSPy01-10" in the dummy dataframe.
I have ever tried to solve this problem by using doBy package. But, I
failed. I ask for the advice on how to use "lapplyBy" function of "doBy"
package.
The commands used and the output I got are as followed:
library(doBy)
df<-orderBy(~group,data=df) # succeeded
f1<-function(x){m<-mean(x, na.ram=TRUE); x[is.na(x)]<-m; x} # succeeded
datatraits<-lapplyBy(traits~group,data=df, FUN=f1(trai...
2010 Jul 08
2
transformation of data.frame
...en3
0016070 gen4
0006511 gen4
I want to rearrange the matrix according to column GO, so that it will look
likes that:
GO:0042787 gen2
GO:0016070 gen2 : gen3 : gen4
GO:0007409 gen1 : gen3
GO:0006511 gen2 : gen4
GO:0006417 gen3
I've tried it with the package doBy (lapplyBy and paste) but it just doesn't
work out.
I will be very happy for any suggestions you might have to help me.
Thanks
Assa
[[alternative HTML version deleted]]
2009 Jun 09
4
how to substitute missing values (NAs) by the group means
...By package. But, I
failed. I ask for the right solutions by using doBy package or not.
The commands used and the output I got are as followed:
library(doBy)
df<-orderBy(~group,data=df) # succeeded
f1<-function(x){m<-mean(x, na.ram=TRUE); x[is.na(x)]<-m; x} # succeeded
datatraits<-lapplyBy(traits~group,data=df, FUN=f1(traits)) # failed
errors: mean(x, na.ram = TRUE), can not find 'traits'.
Thanks in advance.
Sincerely,
Mao J-F
[[alternative HTML version deleted]]
2008 Dec 22
3
Summary information by groups programming assitance
All -
I have data that looks like
psd Species Lake Length Weight St.weight Wr
Wr.1 vol
432 substock SMB Clear 150 41.00 0.01 95.12438
95.10118 0.0105
433 substock SMB Clear 152 39.00 0.01 86.72916
86.70692 0.0105
434 substock SMB Clear 152 40.00 3.11 88.95298
82.03689 3.2655
435 substock SMB Clear
2008 Dec 29
0
Serial Correlation Test for Short Time Series
...y groups programming assitance
To: "Ranney, Steven" <steven.ranney at montana.edu>,
<r-help at r-project.org>
Message-ID:
<C83C5E3DEEE97E498B74729A33F6EAEC05630089 at DJFPOST01.djf.agrsci.dk>
Content-Type: text/plain; charset="iso-8859-1"
Maybe summaryBy (or lapplyBy/splitBy) in the doBy package might help you.
Regards
S?ren
________________________________
Fra: r-help-bounces at r-project.org p? vegne af Ranney, Steven
Sendt: ma 22-12-2008 22:51
Til: r-help at r-project.org
Emne: [R] Summary information by groups programming assitance
All -
I have data t...