When I try and run the Average Nearest Neighbour test on my Shapefile I get the error:
KeyError: u'M' Failed to Execute (AverageNearestNeighbour)
On a "normal" Shapefile this works fine. However I'm trying to use a Shapefile created originally from a CSV with X, Y coordinates. So the overall workflow I have followed is:
- Check format, spacing etc of CSV file. No spaces. Coordinates provided as Eastings and Northings. Made Eastings and Northings into Number format.
- In ArcGIS 10.1 - File>Add Data>Add XY Data.
- Add the CSV file using Easting and Northing as the X and Y fields. Coordinate system is the same. Click okay.
- Right click on the file created >Data>Export Data and save as Shapefile.
- Open the Shapefile in ArcGIS, go to Spatial Statistics>Analyzing Patterns>Average Nearest Neighbour, select the new shapefile, click generate report, click okay...and then the error message comes up.
I can't figure out what I'm doing wrong, does anyone have any ideas?
I'm struggling to find out what that error actually means. I've tried deleting all the unnecessary fields from the CSV file (dates etc) in case that was confusing things, but no luck.
I am a relative beginner.
There are 13,600 fields, which I thought might be the problem. But I tried with a vastly reduced number of rows - down to 800 - but it made no difference.