misolationmap {GeoXp} | R Documentation |
The function misolationmap
draws a scatterplot with the pairwise Mahalanobis distances between the observations and their neighbors on the y-axis and the "degree of isolation" of the observations on the x-axis and a map
misolationmap(long, lat, object,propneighb=0.4,chisqqu=0.975, listvar=NULL, listnomvar=NULL, criteria=NULL, carte = NULL, label = "",cex.lab=1,pch = 16,col="blue", xlab = "degree of isolation", ylab="Pairwise Mahalanobis distances", lablong = "", lablat = "", axes=FALSE)
long |
a vector x of size n |
lat |
a vector y of size n |
object |
a spatial weight matrix of class nb |
propneighb |
proportion of neighbors included in ellipsoid |
chisqqu |
value of alpha for the definition of global outliers |
listvar |
matrix of variables which permit to add graphics such as histogram, etc. and plot bubbles on map using the tlclk window |
listnomvar |
names of variables from listvar |
criteria |
a vector of size n of boolean which permit to represent preselected sites with a cross, using the tcltk window |
carte |
matrix with 2 columns for drawing spatial polygonal contours : x and y coordinates of the vertices of the polygon |
label |
a list of character of size n with name of site. Names are printed on map after a selection |
cex.lab |
character size of label |
pch |
16 by default, symbol for selected points |
col |
"blue" by default, color of the points on the two graphics |
xlab |
a title for the graphic x-axis |
ylab |
a title for the graphic y-axis |
lablong |
name of the x-axis that will be printed on the map |
lablat |
name of the y-axis that will be printed on the map |
axes |
TRUE for drawing axes on the map |
The pairwise Mahalanobis distances are calculated using the robust Minimum Covariance Determinant (MCD)
estimator associated with 75% of observations (function covMcd
in the robustbase package).
For each observation, the degree of isolation is a chi-square quantile of the conditional distribution of the
pairwise Mahalanobis distances associated with the ellipsoid containing the proportion propneighb
of neighbors. The parameter propneighb
gives the proportion of neighbors that is expected to be quite
similar to the observation in order to conclude that the observation is not a local outlier.
Under independence and normality conditions, the user can expect a degree of isolation close by the parameter
propneighb
(vertical line on the scatterplot). An observation with a high degree of isolation is suspected
to be a local outlier. Users have also the possibility to plot bubbles on the map which size depends on the
robust Mahalanobis distance of each observation to the center of the distribution (function arw
in the
package mvoutlier).
A matrix of boolean of size n x n
Fizmoser P., Thomas-Agnan C., Ruiz-Gazen A., Laurent T.,
Aragon Yves, Perrin Olivier, Ruiz-Gazen Anne, Thomas-Agnan Christine (2009), Statistique et Econométrie pour données géoréférencées : modèles et études de cas
data(moss) data(kola.background) xy <- moss[,c("XCOO","YCOO")] xy.knn <- knearneigh(as.matrix(xy), k=15) #xy.knn <- dnearneigh(as.matrix(xy), 0,50000 ) nb.kola <- knn2nb(xy.knn) dat.kola <- log10(moss[, c("Ag","As","Bi","Cd","Co","Cu","Ni")]) obs<-misolationmap(xy$XCOO,xy$YCOO,nb.kola,propneighb=0.40,chisqqu=0.975,dat.kola,names(dat.kola),col='royalblue',pch=7, carte= kola.background,cex.lab=0.7)