derivative of Lq, which is not differentiable at x == 0.
Usage
d.Lq(x, lambda = 1, q = 1, d.side = "both")
Arguments
x
numeric.
lambda
non-negative scalar, shrinkage parameter.
q
non-negative scalar, norm parameter..
d.side
side of serivative at origin. Default value is "both", returning NA for x == 0. If set to "RHS", then returns RHS derivative, i.e., \(\lambda\), and \(-\lambda\) with "LHS".
Value
derivative of Lq(x), i.e., $$L^q(x) = q\lambda | x|^{q-1}$$, for x == 0 return value is NA.