Library: | gam |
See also: | gamfit gamopt gintest |
Macro: | gamout | |
Description: | creates a nice output for GAM. ! auxiliary macro ! |
Usage: | gamout(x,y,m,b,const{,opt}) | |
Input: | ||
x | n x p matrix, the predictor variables. | |
y | n x 1 vector, the response variables. | |
m | n x dd matrix, estimated functions. | |
b | p x 1, estimated coefficients. | |
const | scalar, the estimated constant. | |
opt | optional list, a list with optional input. The macro "gamopt" can be used to set up this parameter. The order of the list elements is not important. Parameters which are not given are replaced by defaults. For details see gamopt. |
library("gam") n=100 b=1|2 p=rows(b) x=2.*uniform(n,p)-1 t=2.*uniform(n,1)-1 y=x*b+t^3+normal(n)./2 opt=gamopt("x",x,"pl",1) {m,b,const}=backfit(t,y,1,0,"qua",opt) gamout(t,y,m,b,const,opt)
Display(s) with estimated functions, data points and more
Library: | gam |
See also: | gamfit gamopt gintest |