powered by
Function to check whether a polynomial is montone over a given interval.
ismonotone(object, …)# S3 method for monpol ismonotone(object, a = -Inf, b = Inf, EPS = 1e-06, …)# S3 method for default ismonotone(object, a = -Inf, b = Inf, EPS = 1e-06, …)
# S3 method for monpol ismonotone(object, a = -Inf, b = Inf, EPS = 1e-06, …)
# S3 method for default ismonotone(object, a = -Inf, b = Inf, EPS = 1e-06, …)
Either an object of class ‘
monpol
Lower limit of the interval over which the polynomial should be montone.
Upper limit of the interval over which the polynomial should be montone.
Numerical precision, values with absolute value smaller than EPS are treated as zero.
Further arguments passed to or from other methods.
TRUE or FALSE depending on whether the polynomial is montone over (a,b) or not.
TRUE
FALSE
Note that due to numerical precision issues it is possible that a polynomial that should be monotone is declared to be not monotone.
# NOT RUN { fit <- monpol(y~x, w0) ismonotone(fit) beta <- c(1,0,2) ## the polynomial 1 + 2*x^2 ismonotone(beta) ismonotone(beta, a=0) ismonotone(beta, b=0) # }
Run the code above in your browser using DataLab