Spherical regression using the ESAG distribution | R Documentation |
Spherical regression using the ESAG distribution.
esag.reg(y, x, con = TRUE, xnew = NULL, lati = 10, longi = 10, tol = 1e-06)
y |
A matrix with 3 columns containing the (unit vector) spherical data. |
x |
The predictor variable(s), they can be continnuous, spherical, categorical or a mix of them. |
con |
Do you want the constant term in the regression? |
xnew |
If you have new data use it, otherwise leave it NULL. |
lati |
A positive number determing the range of degrees to move left and right from the latitude center. This number and the next determine the grid of points to search for the Q matrix described in Paine et al. (2020). |
longi |
A positive number determing the range of degrees to move up and down from the longitude center. This number and the previous determine the grid of points to search for the Q matrix described in Paine et al. (2020). |
tol |
A tolerance value to decide when to stop the successive optimizations. |
The second parametrization of the ESAG regression (Paine et al., 2020) is applied.
A list including:
loglik |
The log-likelihood of the regression model. |
param |
A vector with three numbers. A measure of fit of the estimated values, defined as |
gam |
The two |
beta |
The beta coefficients. |
seb |
The standard error of the beta coefficients. |
est |
The fitted values of xnew if "xnew" is NULL. If it is not NULL, the fitted values for the "xnew" you supplied will be returned. |
Michail Tsagris.
R implementation and documentation: Michail Tsagris mtsagris@uoc.gr.
P. J. Paine, S. P. Preston, M. Tsagris and Andrew T. A. Wood (2020). Spherical regression models with general covariates and anisotropic errors. Statistics and Computing, 30(1): 153–165. https://link.springer.com/content/pdf/10.1007
esag.mle, iag.reg, spml.reg
y <- resag( 25, rnorm(3), c(1, 1) )
## this is a small example to pass CRAN's check because the default argument values
## of lati and longi require many seconds
a <- esag.reg(y, iris[1:25, 4], lati = 2, longi = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.