New answers tagged

1

Yes you can use join-counts (not "joint counts") for spatial point data autocorrelation measure. Here's how with discussion on appropriate weight matrix decision: First let's make some data: > set.seed(123) > pts = st_as_sf(data.frame(x=runif(50),y=runif(50)),coords=1:2) > pts$S = factor(sample(c("Presence","Absence"),...


3

Let's make some data: > set.seed(123) > pts = st_as_sf(data.frame(x=runif(50),y=runif(50)),coords=1:2) > pts$S = factor(sample(c("Presence","Absence"),nrow(pts),TRUE)) > plot(pts,pch=19) To do join-counts, you need to decide where the joins are. For a grid that's usually the 4- or 8- nearest neighbours (rook or queen ...


1

I had the same doubt myself, and contrary to what some other people suggested you to do in the answers above, from the source code it is not straightforward what all those concepts mean. However, according to the answer from rafa.pereira here, gwr.e are the residuals. Regarding EDF, Roger Bivand and Danlin Yu, who are the developers of the package, indicate ...


1

Michael Dorman's answer looks quite similar to this PostGIS question, which was answered in more detail at this blog post. R's sf and PostGIS are similar in that they both build on the GEOS library, but don't have quite the same set of functions. Unfortunately I don't think the n.overlaps column in the result of sf::st_intersection() is counting what was ...


1

One way to define an "average polygon" could be the area covered by at least 50% of simulated polygons. Here is how this can be calculated using sf: library(sf) # Combine pol = kernel.poly.all pol = do.call(rbind, pol) pol = st_as_sf(pol) # Calculate average polygon pol_avg = st_intersection(pol) pol_avg = pol_avg[pol_avg$n.overlaps >= nrow(...


1

I couldn't get the above method to work so have developed a different version. Hopefully helpful to someone in the near future. require(sf) require(dplyr) require(ggplot2) # pick a grid cell size ovrGridSize <- 50000 # import data and reproject pol <- sf::st_read(system.file("shape/nc.shp", package="sf")) %>% st_transform(...


Top 50 recent answers are included