R/wild-codes.R

setMethod("wild.codes","item",function(x){
  vl <- labels(x)
  vvl <- vl@values
  use <- !(x %in% vvl)
  N <- length(x)
  x <- x@.Data[use]
   
  tab <- Table(x,counts=TRUE,percentage=TRUE)
  tab[,2] <- 100*tab[,1]/N
  tab
})

Try the memisc package in your browser

Any scripts or data that you put into this service are public.

memisc documentation built on March 31, 2023, 7:29 p.m.