p2j: Extract the column index from a sparse matrix

Description Usage Arguments Examples

Description

Extract the column index from a sparse matrix

Usage

1
2
3
4
p2j(x, ...)

## S3 method for class 'dgCMatrix'
p2j(x)

Arguments

x

sparse matrix

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
p2j <- lavaSearch2:::p2j
initVcoef.lvm <- lavaSearch2:::initVcoef.lvm

m <- lvm(Y~X1+X2+X3)
V <- initVcoef.lvm(m, link = coefReg(m), group = 1:length(coefReg(m)))
p2j(V)
p2j(cbind(V,0,V))
p2j(cbind(0,V,0,V))

V2 <- rbind(1,V)
p2j(V2)
p2j(cbind(0,V2,0,V2))

bozenne/lava.penalty documentation built on May 13, 2019, 1:41 a.m.