gam2objective              package:mgcv              R Documentation

_O_b_j_e_c_t_i_v_e _f_u_n_c_t_i_o_n_s _f_o_r _G_A_M _s_m_o_o_t_h_i_n_g _p_a_r_a_m_e_t_e_r _e_s_t_i_m_a_t_i_o_n

_D_e_s_c_r_i_p_t_i_o_n:

     Estimation of GAM smoothing parameters is most stable if
     optimization of the UBRE/AIC or GCV score is outer to the
     penalized iteratively re-weighted least squares scheme used to
     estimate the model given smoothing  parameters. These functions
     evaluate the GCV/UBRE/AIC score of a GAM model, given smoothing
     parameters, in a manner suitable for use by 'optim' or 'nlm'. Not
     normally called directly, but rather service routines for
     'gam.outer'.

_U_s_a_g_e:

     gam2objective(lsp,args,...)
     gam2derivative(lsp,args,...)

_A_r_g_u_m_e_n_t_s:

     lsp: The log smoothing parameters.

    args: List of arguments required to call 'gam.fit3'.

     ...: Other arguments for passing to 'gam.fit3'.

_D_e_t_a_i_l_s:

     'gam2objective' and 'gam2derivative' are functions suitable for
     calling by 'optim', to evaluate the GCV/UBRE/AIC score and its
     derivatives w.r.t. log smoothing parameters.

     'gam4objective' is an equivalent to 'gam2objective', suitable for
     optimization by 'nlm' - derivatives of the GCV/UBRE/AIC function
     are calculated and returned as attributes.

     The basic idea of optimizing smoothing parameters `outer' to the
     P-IRLS loop was first proposed in O'Sullivan et al. (1986).

_A_u_t_h_o_r(_s):

     Simon N. Wood simon.wood@r-project.org

_R_e_f_e_r_e_n_c_e_s:

     O 'Sullivan, Yandall & Raynor (1986) Automatic smoothing of
     regression functions in generalized linear models. J. Amer.
     Statist. Assoc. 81:96-103.

     Wood, S.N. (2008) Fast stable direct fitting and smoothness
     selection for generalized additive models. J.R.Statist.Soc.B
     70(3):495-518

     <URL: http://www.maths.bath.ac.uk/~sw283/>

_S_e_e _A_l_s_o:

     'gam.fit3',  'gam', 'mgcv', 'magic'

