Hi all,

Thanks to each and every one of you who replied to my call for help
regarding my issue with ArcMap crashing in the middle of a spatial join
between a point file and a polygon shapefile. Some of the replies I received
included the following suggestions:

- The Near tool, Near 3D tool, or Generate near table tool
- Modification of the "guts" of ArcMap, including disabling background
processing so that a progress bar appears and coding the join into ArcMap
vs. just pressing a button (i.e., using Python)
-Splitting the dataset into chunks and processing each individually
-Using the resources at  https://gis.stackexchange.com/

I ended up working around the instability of ArcMap by continuing my
analyses in R. Thanks to everyone who suggested this as an option, and
thanks to everyone who replied to offer their expertise! Here is a sample of
the code I used in R; I hope it helps someone in the future who encounters
this issue.

# lpb2 is my points file
coords <- cbind(lpb2$Long, lpb2$Lat)
coordsSP <- SpatialPoints(coords, proj4string=CRS(as.character(NA)))
crs.geo <- CRS("+init=EPSG:32604")  # WGS 84 / UTM zone 4N 
proj4string(coordsSP) <- crs.geo  # define projection system of our data
is.projected(coordsSP)
summary(coordsSP)
df<- lpb2[3:6] # Make covariates their own df
SPdf <- SpatialPointsDataFrame(coordsSP,df)
summary(SPdf)

# Read in my polygon

Molokai <- readOGR(dsn = 'Molokai', layer = 'Molokai') # Made folder named
Molokai and placed my Molokai shp in there

# Calculate distances from each point

Dist <- gDistance(SPdf, Molokai, byid=T)
class(Dist)
tDist <- t(Dist) # transpose the matrix
colnames(tDist)[1]<- 'Dist'
lpb2 <- cbind(lpb2, tDist)

Reply via email to