Skip to contents

NMF Frobenius objective (Geron Ch 8, morie.fn grnmfo)

Usage

morie_geron_nmf_objective(X, W, H)

Arguments

X, W, H

Non-negative matrices with X ~ W H.

Value

List with objective, reconstruction, residual, relative_error, rank.

Examples

morie_geron_nmf_objective(X = 5L, W = 5L, H = 0.5)
#> $objective
#> [1] 6.25
#> 
#> $reconstruction
#>      [,1]
#> [1,]  2.5
#> 
#> $residual
#>      [,1]
#> [1,]  2.5
#> 
#> $relative_error
#> [1] 0.5
#> 
#> $rank
#> [1] 1
#> 
#> $estimate
#> [1] 6.25
#> 
#> $n
#> [1] 1
#>