Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Library: smoother
See also: lpregest lpregxest lpderest gasmregx

Quantlet: gasmregxb
Description: calculates the Gasser-Mueller estimator using quartic boundary kernel

Reference(s):

Usage: out = gasmregxb(data, h{, x})
Input:
data n x 2 matrix containing data
h scalar, bandwidth
x optional m x 1 vector which indicates where to calculate the estimates, default is the first column of data
Output:
out m x 2 matrix containing the estimated regression function

Note:

Example:
library("smoother")
pts=100
b=0.4
randomize(12345)
x=pi*((1:pts)/pts)
x=x~(sin(x)+0.5*normal(pts))
x[,2]=x[,2]-2
est0=gasmregx(x,b,0,x[,1])
est1=gasmregxb(x,b,x[,1])
di=createdisplay(1,2)
xp=setmask(x,"fillcircle","small")
est0p=setmask(est0,"line","thin")
est1p=setmask(est1,"line","thin")
show(di,1,1,xp,est0p)
show(di,1,2,xp,est1p)

Result:
Display showing the estimates of the regression curve
with and without the boundary correction



Author: Z. Hlavka, 20020913 license MD*Tech
(C) MD*TECH Method and Data Technologies, 05.02.2006