soft.threshold: The function soft.threshold() soft-thresholds a vector such...

Description Usage Arguments Value Examples

View source: R/soft.threshold.R

Description

The function soft.threshold() soft-thresholds a vector such that the L1-norm constraint is satisfied.

Usage

1
  soft.threshold(x, sumabs = 1)

Arguments

x

A numeric vector.

sumabs

A numeric constraint on x's L1 norm.

Value

Returns a vector resulting from the soft thresholding of x given sumabs

Examples

1
2
x <- rnorm(10)
soft.threshold(x,0.5)

ecamenen/r-rgcca documentation built on Jan. 16, 2020, 12:50 a.m.