formulas_to_constraint_list: A helper function for 'polygram'. Creates a list of...

Description Usage Arguments Details Value

View source: R/helpers.R

Description

A helper function for polygram. Creates a list of constraints out of a formula, ms, ps and s.

Usage

1
formulas_to_constraint_list(form, ms, s, ps)

Arguments

form

a formula

ms

segrees of Bernstein densities

s

split points

ps

connectivity constraints

Details

Currently supported options are:

  1. "convex", "concave"; both together produces straight line.

  2. "decreasing", "increasing"; both together produces uniform.

  3. "symmetric"

  4. mean: Takes two "arguments", one in c("=", ">=", "=<") and a numeric in support.

  5. moment: Takes three "arguments", one in c("=", ">=", "=<"), a numeric in support, and a natural specifying the moment.

  6. quantile: Takes three "arguments", one in c("=", ">=", "=<"), a numeric

  7. quantile: Takes three "arguments", one in c("=", ">=", "=<"), a numeric in support, and a float in (0,1) specifying the quantile.

Value

A list containing a 1.) a constraint matrix, 2.) lower bounds and 3.) upper bounds.


JonasMoss/polygrams documentation built on Nov. 8, 2019, 5:19 p.m.