Skip to contents

Projected PMD of a matrix.

Usage

pPMD(
  Data,
  k = 2L,
  rdsLeft = rep(1, k),
  rdsRight = rep(1, k),
  tol.si = .Machine$double.eps
)

Arguments

Data

the rectangular matrix to decompose ;

k

the desired rank of the singular decomposition (default to 2) ;

rdsLeft

a vector of radiuses (>0) of the $L_1$ or $L_G$ balls for each of the k left vectors ;

rdsRight

a vector of radiuses (>0) of the $L_1$ or $L_G$ balls for each of the k right vectors ;

tol.si

tolerance for the sparsity

Value

Pseudo-singular vectors and values

Author

Vincent Guillemot, Ju-Chi Yu

Examples

X <- matrix(rnorm(20), 5, 4)
pPMD(X)
#> $d
#> [1] 2.528738 1.476340
#> 
#> $u
#>      [,1] [,2]
#> [1,]    0    0
#> [2,]    0    0
#> [3,]    1    0
#> [4,]    0    0
#> [5,]    0   -1
#> 
#> $v
#>      [,1] [,2]
#> [1,]    0    0
#> [2,]    0    0
#> [3,]    0   -1
#> [4,]    1    0
#> 
#> $rdsLeft
#> [1] 1 1
#> 
#> $rdsRight
#> [1] 1 1
#> 
pPMD(
  X,
  k = 3L,
  rdsLeft = rep(0.5 * sqrt(5), 3),
  rdsRight = rep(0.5 * sqrt(4), 3))
#> $d
#> [1] 2.7292513 1.3837271 0.9913628
#> 
#> $u
#>            [,1]        [,2]       [,3]
#> [1,]  0.0000000  0.03690889  0.0000000
#> [2,]  0.0000000 -0.08546704 -0.9920297
#> [3,]  0.9920297  0.00000000  0.0000000
#> [4,]  0.0000000  0.00000000  0.1260040
#> [5,] -0.1260041 -0.99565713  0.0000000
#> 
#> $v
#>      [,1] [,2] [,3]
#> [1,]    0    0    0
#> [2,]    0    0    1
#> [3,]    0   -1    0
#> [4,]    1    0    0
#> 
#> $rdsLeft
#> [1] 1.118034 1.118034 1.118034
#> 
#> $rdsRight
#> [1] 1 1 1
#>