Displaying 8 results from an estimated 8 matches for "grand_col".
2009 Apr 17
1
cast function in package reshape
...0x03d6c930>
I would like to use this list of functions with cast function (in package
reshape by Hadley Wickham) :
> cast(melt(df, id = c("id", "z"), measure = c("x", "y")), variable +
result_variable ~ z, fun = function(x) freq1(x), margins = "grand_col")
Erreur dans freq1(x) : objet "res" non trouvé
Here the result I would like to have :
variable a b (all)
1 x freq_1 10 14 24
2 y freq_1 18 32 50
3 y freq_2 9 14 23
I admit it is a bit far-fetched, but i...
2010 Sep 10
0
reshape2: a reboot of the reshape package
...eed of subsetting to the
fullest extent, in most cases only making a single copy of the data.
* cast is replaced by two functions depending on the output type: `dcast`
produces data frames, and `acast` produces matrices/arrays.
* multidimensional margins are now possible: `grand_row` and `grand_col` have
been dropped: now the name of the margin refers to the variable that has
its value set to (all).
* some features have been removed such as the `|` cast operator, and the
ability to return multiple values from an aggregation function. I'm
reasonably sure both these operations...
2011 Jan 04
0
reshape2 1.1
...eed of subsetting to the
fullest extent, in most cases only making a single copy of the data.
* cast is replaced by two functions depending on the output type: `dcast`
produces data frames, and `acast` produces matrices/arrays.
* multidimensional margins are now possible: `grand_row` and `grand_col` have
been dropped: now the name of the margin refers to the variable that has
its value set to (all).
* some features have been removed such as the `|` cast operator, and the
ability to return multiple values from an aggregation function. I'm
reasonably sure both these operations...
2010 Sep 10
0
reshape2: a reboot of the reshape package
...eed of subsetting to the
fullest extent, in most cases only making a single copy of the data.
* cast is replaced by two functions depending on the output type: `dcast`
produces data frames, and `acast` produces matrices/arrays.
* multidimensional margins are now possible: `grand_row` and `grand_col` have
been dropped: now the name of the margin refers to the variable that has
its value set to (all).
* some features have been removed such as the `|` cast operator, and the
ability to return multiple values from an aggregation function. I'm
reasonably sure both these operations...
2011 Jan 04
0
reshape2 1.1
...eed of subsetting to the
fullest extent, in most cases only making a single copy of the data.
* cast is replaced by two functions depending on the output type: `dcast`
produces data frames, and `acast` produces matrices/arrays.
* multidimensional margins are now possible: `grand_row` and `grand_col` have
been dropped: now the name of the margin refers to the variable that has
its value set to (all).
* some features have been removed such as the `|` cast operator, and the
ability to return multiple values from an aggregation function. I'm
reasonably sure both these operations...
2013 Jun 26
1
Margins in dcast (reshape2)
Hi,
I'd like to get mean values for the margins of my casted data.frame.
For the casting I am using dcast() from reshape2. However, when I set
the margins parameter (margins=c("grand\_row")) I get following error
concerning
an unrecognized escape character '\_'. So what is the correct command
to get the outermost margins only in reshape2?
/johannes
[[alternative HTML
2011 Oct 23
2
Summary stats in table
Suppose I have data like this:
A <- sample(letters[1:3], 1000, replace=TRUE)
B <- sample(LETTERS[1:2], 1000, replace=TRUE)
x <- rnorm(1000)
I can get a table of means via
tapply(x, list(A, B), mean)
and I can add the marginal means to this using cbind/rbind:
main <- tapply(x, list(A,B), mean)
Amargin <- tapply(x, list(A), mean)
Bmargin <- tapply(x, list(B), mean)
2011 Apr 20
3
[test message] Can R replicate this data manipulation in SAS?
Apologies for troubling the list, but it is a test that
needs to be carried out. I am resending the message that
I sent earlier on behalf of Paul Miller, but with a
certain word used in the variables names of the SAS code
changed to a different word.
With thanks for your tolerance ...
Ted.
[*** PLEASE NOTE: I am sending this message on behalf of
Paul Miller:
Paul Miller <pjmiller_57 at