w0: Simulated w0 data used in Murray et al. (2013)

Description Format Source Examples

Description

This data set gives simulated data from the function

y = 0.1x^3 + e

for e ~ N(0,0.01^2) and x evenly spaced between -1 and 1.

Format

A data frame with 21 observations on the following 2 variables.

y

a numeric vector

x

a numeric vector

Source

Murray, K., M<c3><bc>ller, S. and Turlach, B.A. (2013). Revisiting fitting monotone polynomials to data, Computational Statistics 28(5): 1989–2005, doi: 10.1007/s00180-012-0390-5.

Examples

1
2
3
str(w0)
plot(y~x, w0)
monpol(y~x, w0)

Example output

Loading required package: quadprog
'data.frame':	21 obs. of  2 variables:
 $ y: num  -0.0847 -0.0598 -0.042 -0.0397 -0.0299 ...
 $ x: num  -1 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 ...

Monotone polynomial model
Call:
monpol(formula = y ~ x, data = w0)

Coefficients:
    beta0      beta1      beta2      beta3  
-0.004059   0.015497   0.008259   0.072618  

MonoPoly documentation built on May 2, 2019, 7:59 a.m.

Related to w0 in MonoPoly...