softK: Soft-thresholding operator

Description Usage Arguments Value Author(s) Examples

View source: R/softK.R

Description

Soft-thresholding operator, which is called by mbpca.

Usage

1
softK(x, k)

Arguments

x

A numerical vector

k

Number of non-zero elements want to keep

Value

A numerical vector

Author(s)

Chen Meng

Examples

1
2
v <- rnorm(10)
softK(v, k = 2)

mengchen18/mogsa documentation built on Nov. 23, 2017, 1:57 a.m.