predict.trls package:spatial R Documentation _P_r_e_d_i_c_t _m_e_t_h_o_d _f_o_r _t_r_e_n_d _s_u_r_f_a_c_e _f_i_t_s _D_e_s_c_r_i_p_t_i_o_n: Predicted values based on trend surface model object _U_s_a_g_e: ## S3 method for class 'trls': predict(object, x, y, ...) _A_r_g_u_m_e_n_t_s: object: Fitted trend surface model object returned by 'surf.ls' x: Vector of prediction location eastings (x coordinates) y: Vector of prediction location northings (y coordinates) ...: further arguments passed to or from other methods. _V_a_l_u_e: 'predict.trls' produces a vector of predictions corresponding to the prediction locations. To display the output with 'image' or 'contour', use 'trmat' or convert the returned vector to matrix form. _R_e_f_e_r_e_n_c_e_s: Venables, W. N. and Ripley, B. D. (2002) _Modern Applied Statistics with S._ Fourth edition. Springer. _S_e_e _A_l_s_o: 'surf.ls', 'trmat' _E_x_a_m_p_l_e_s: data(topo, package="MASS") topo2 <- surf.ls(2, topo) topo4 <- surf.ls(4, topo) x <- c(1.78, 2.21) y <- c(6.15, 6.15) z2 <- predict(topo2, x, y) z4 <- predict(topo4, x, y) cat("2nd order predictions:", z2, "\n4th order predictions:", z4, "\n")