Displaying 1 result from an estimated 1 matches for "ostbet".
Did you mean:
ostate
2003 May 14
2
how to include 'NA's in xtabs?
Hello!
I have a dataset with NA's in some variables (factors), for example:
$ P67 : Factor w/ 2 levels "-","+": NA 2 1 NA NA 2 1 1 2 NA ...
I need to use 'xtabs' like
xtabs(~x$P67)
It works well and produces something like this:
x$P67
- +
779 1318
but i want to compute NA's too, like this:
x$P67
- + NA
779 1318 137
I am trying