[R] question for crosstable

From: eugen pircalabelu <eugen_pircalabelu_at_yahoo.com>
Date: Sun, 09 Mar 2008 11:09:07 -0700 (PDT)

Good evening R-users!

I have the following problem: i want to get a weighted crosstable along with the adjusted standardized residuals test


 d<-c("a", "b","b","c","a","a","a", "b", "c","c")
 z<-data.frame(a, b,c,d)


Using the above example i want to get this :

xtabs(c ~ a+d, z) ,                 where i have 
sum(xtabs(c ~ a+d, z) )         as my total number of cases, but with the adjusted standardized residuals test. 

So i want something like the CrossTable function from gmodels package, but taking into account that i have weights which sum to 24 and not 10, as the CrossTable prints from this:

 CrossTable(z$a, z$d, format="SPSS", asresid=T)

Thank you and have a great day ahead!        

        [[alternative HTML version deleted]]

R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Sun 09 Mar 2008 - 18:13:06 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Sun 09 Mar 2008 - 19:30:26 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive