Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

Huber-class

The Huber class.


Description

This class represents the elementwise Huber function, Huber(x, M) =

  • 2M|x|-M^2for |x| ≥q |M|

  • |x|^2for |x| ≤q |M|.

Usage

Huber(x, M = 1)

## S4 method for signature 'Huber'
to_numeric(object, values)

## S4 method for signature 'Huber'
sign_from_args(object)

## S4 method for signature 'Huber'
is_atom_convex(object)

## S4 method for signature 'Huber'
is_atom_concave(object)

## S4 method for signature 'Huber'
is_incr(object, idx)

## S4 method for signature 'Huber'
is_decr(object, idx)

## S4 method for signature 'Huber'
is_quadratic(object)

## S4 method for signature 'Huber'
get_data(object)

## S4 method for signature 'Huber'
validate_args(object)

## S4 method for signature 'Huber'
.grad(object, values)

Arguments

x

An Expression object.

M

A positive scalar value representing the threshold. Defaults to 1.

object

A Huber object.

values

A list of numeric values for the arguments

idx

An index into the atom.

Methods (by generic)

  • to_numeric: The Huber function evaluted elementwise on the input value.

  • sign_from_args: The atom is positive.

  • is_atom_convex: The atom is convex.

  • is_atom_concave: The atom is not concave.

  • is_incr: A logical value indicating whether the atom is weakly increasing.

  • is_decr: A logical value indicating whether the atom is weakly decreasing.

  • is_quadratic: The atom is quadratic if x is affine.

  • get_data: A list containing the parameter M.

  • validate_args: Check that M is a non-negative constant.

  • .grad: Gives the (sub/super)gradient of the atom w.r.t. each variable

Slots

x

An Expression or numeric constant.

M

A positive scalar value representing the threshold. Defaults to 1.


CVXR

Disciplined Convex Optimization

v1.0-10
Apache License 2.0 | file LICENSE
Authors
Anqi Fu [aut, cre], Balasubramanian Narasimhan [aut], David W Kang [aut], Steven Diamond [aut], John Miller [aut], Stephen Boyd [ctb], Paul Kunsberg Rosenfield [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.