isoreg(x, y = NULL) ## S3 method for class 'isoreg': print(x, digits = getOption("digits"), ...) ## S3 method for class 'isoreg': as.stepfun(x, ...) ## S3 method for class 'isoreg': fitted(object, ...) ## S3 method for class 'isoreg': residuals(object, ...)
x, y |
numeric predictor and response vectors, respectively.
The inputs x and y will be processed by xy.coords
so they may be in the form of a list (whose components are named x
and y), a two-column matrix, a ts (time series) object,
or a complex vector. If y is missing then x is used as
y and seq_along(x) is used as x.
See xy.coords for more details.
No NAs are allowed. In print.isoreg and as.stepfun.isoreg, x is an object of class "isoreg", as returned by the isoreg() function. |
digits | the number of significant digits that should be printed. |
... | other optional argument pass to or from print method. The other methods that accept ... silently ignore them. |
x | the input predictor values. |
y | the input response values. |
yf | the fitted values corresponding to ordered x values |
yc | the cumulative sums of y values corresponding to ordered x values. |
iKnots | an integer vector giving the indices (into the sorted x) of breakpoints in the step function. |
isOrd | logical value which is TRUE if the input x is in sorted order and FALSE if it is unsorted. |
ord | if isOrd is TRUE, the indices such that x[ord] is in sorted order. Otherwise NULL. |
call | matched call. |
x <- c(101, 103, 107, 107, 110, 111) y <- c( 33, 34, 33, 36, 34, 37) irFit <- isoreg(x, y) irFit sum(residuals(irFit)^2) as.stepfun(irFit)(seq(100, 112, by=1/2)) # prediction