constant

0th

Percentile

Get or set the constant term of a spray object

The constant term of a spray object is the coefficient corresponding to an index of all zeros. These functions get or set the constant of a spray object.

Keywords
symbolmath
Usage
constant(S,drop=FALSE)
constant(S) <- value
Arguments
S

Object of class spray

value

Numeric value to set the constant coefficient to

drop

Boolean, with default FALSE meaning to return a spray object and TRUE meaning to return a numeric value

Value

In function constant(), return the coefficient, or a constant multivariate polynomial, depending on the value of drop.

Note

The behaviour of drop (sort of) matches that of the spray extractor method.

See Also

Extract

Aliases
  • constant
  • constant<-
Examples
# NOT RUN {
S <- spray(partitions::blockparts(rep(2,4),3,TRUE))

constant(S)

constant(S) <- 33

S

# }
Documentation reproduced from package spray, version 1.0-8, License: GPL (>= 2)

Community examples

Looks like there are no examples yet.