I have a data-set containing rain value for 6 stations and station coordinates (lat,lon). I used lm function taking lat,lon,day, their interaction and rain as below:
G <- auto_basis(data = Rain[,c("lon","lat")] %>% *# Take dataset*
SpatialPoints(), # To sp obj
nres = 1, # One resolution
type = "Gaussian")
S <- eval_basis(basis = G, # basis functions
s = Rain[,c("lon","lat")] %>% # spat locations
as.matrix()) %>% # conv. to matrix
as.matrix() # results as matrix
colnames(S) <- paste0("B", 1:ncol(S)) # assign column names
Rain2<- cbind(Rain, S) %>% # append S to dataset
select( -mydate) # will not be using in the model
Rain_lm <- lm(z ~ (lon + lat + day)^2 + ., # model
data = select(Rain2,-id)) # omit station id
Rain_lm %>% summary()
The LM summary shows NA for Estimate regression coefficients and the standard errors Std. Error and of lat:lon interaction . Could you please help me to interpret the producing NAs?