I tried to get the map of Wisconsin and try to do Clark-Evans test on spatial data points. However, when I import the map of wisconsin and try to convert it into a window, I met the error:
Warning message: 244 points were rejected as lying outside the specified window
I used the following code:
wisc.map <- map("state", "wisconsin", fill=T)
w <- owin(poly=data.frame(x=rev(wisc.map$x), y=rev(wisc.map$y)))
And I got error after I ran
spat = as.ppp(data, w)
It is clearly that all my data points are in Wisconsin like the plot showed below:
I put some sample data here:
latitude longitude
1 43.30716 -89.43137
2 43.30388 -89.42823
3 43.31845 -89.44372
4 43.33766 -89.44634
5 43.50815 -89.52010
6 43.34179 -89.01988
Any idea for what's going on?
Thanks
P.S I want to do a Clark Evans Test because I want to check whether there exists clustering pattern among my data. I want to make sure the hotspots obtained from data is statistical significant. I checked many literatures but didn't find the direct way to test it, so I have to use Clark Evans Test... Anyone knows any better tests to check clustering pattern or hotspot significance?