How can I remove an entire column/row of an atomic vector in R?
Everything I found about this on Q&A sites won't work...
Everytime I get a different error:
:= is not an operator
$ not working on atomic vectors
number of items to replace is not a multiple of replacement length
This is my data
> print(nominalTable)
MORTGAGE NONE OTHER OWN RENT
36 months 854 1 4 165 928
60 months 294 0 1 35 218
I want to remove the NONE
and OTHER
columns so that the mosaicplot
would ignore them.
UPDATE
> dput(nominalTable)
structure(c(854L, 294L, 1L, 0L, 4L, 1L, 165L, 35L, 928L, 218L
), .Dim = c(2L, 5L), .Dimnames = structure(list(c("36 months",
"60 months"), c("MORTGAGE", "NONE", "OTHER", "OWN", "RENT")), .Names = c("",
"")), class = "table")