| To: | s-news@lists.biostat.wustl.edu |
|---|---|
| Subject: | groupMeans |
| From: | "Ronald WH Verwer" <r.verwer@nin.knaw.nl> |
| Date: | Fri, 27 Jan 2006 14:15:33 +0100 |
| Reply-to: | r.verwer@nin.knaw.nl |
|
Dear All,
I am using S+ v6.2 on Windows XP
Could anybody comment on this problem I encounter using
groupMeans?
> library(resample,first=T)
> options(conflicts.ok=T)
> x
[,1] [,2]
[1,] 3217.391 2
[2,] 4357.143 2
[3,] 3692.308 2
[4,] 4000.000 2
[5,] 11250.000 1
[6,] 11111.111 1
[7,] 7600.000 1
> v <- groupMeans(x[,1],x[,2])
Problem in mean: argument weights= not matched: mean(x[i],
weights = weights[i], na.rm = na.rm)
Use traceback() to see the call stack
> traceback()
12: eval(action, sys.parent())
11: doErrorAction("Problem in mean: argument weights= not
matched: mean(x[i], weights = weights[i
], na.rm = na.rm)",
10: mean(x[i], weights = weights[i], na.rm = na.rm)
9: FUN(...X.sub.i...., x = c(3217.39130434783,
4357.14285714286, 3692.30769230769, 4000., 11250.,
8: list(
7: NULL
6: lapply(X, FUN, x = ..1, weights = ..2, na.rm = ..3)
5: sapply(group.inds, function(i, x, weights, na.rm)
4: gm(x, group.inds, weights, na.rm)
3: groupMeans(x[, 1], x[, 2])
2: eval(_expression_(v <- groupMeans(x[, 1], x[, 2])))
1:
Message: Problem in mean: argument weights= not matched:
mean(x[i], weights = weights[i], na.rm =
na.rm)
>
Thank you in advance.
Kind regards,
Ronald
Ronald W.H. Verwer
Netherlands Institute for Neuroscience
Meibergdreef 33
1105 AZ Amsterdam
The Netherlands
tel: 020-5665518
fax: 020-6961006
email: r.verwer@nin.knaw.nl
web-site:www.nin.knaw.nl/~verwer
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: Alternative to model.tables.aov?, Thompson, David (MNR) |
|---|---|
| Next by Date: | assignment, Eric yang |
| Previous by Thread: | Re: Calculating Averages for several, Richard M. Heiberger |
| Next by Thread: | Re: groupMeans, Tim Hesterberg |
| Indexes: | [Date] [Thread] [Top] [All Lists] |