R/insertval2.R

insertval2 <-
function (x, nmod) 
{
    xx <- matrix(0, length(x), nmod)
    for (i in 1:length(x)) xx[i, x[i]] <- 1
    list(xx = xx)
}

Try the MCAvariants package in your browser

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

MCAvariants documentation built on Sept. 7, 2020, 5:10 p.m.