Quantcast
Channel: Forums - ArcGIS for Desktop - General
Viewing all articles
Browse latest Browse all 2328

Error creating shapefile

$
0
0
So I am working from my laptop using ArcMap 10.1 on a GIS class lab and am running into the same problem. At first I thought it was maybe the data sets I was using but now it seems to be the ArcGIS software itself. In the task I am creating different shapefiles from selections I make. Here are the steps I am taking as for my lab...

1.) I first opened ArcMap and loaded the “buffer_no_lakes” shapefile and the “malformed_frog_locations.csv” file. I then had to set the coordinate system for the .csv file by right clicking on it and clicking “display XY data”. I then set x to longitude and y to latitude and clicked edit. I then navigated to the “geographic coordinate system” folder then to the “world” folder and then clicked on “WGS 1984” and pressed ok and ok. On the pop up menu I also clicked ok.
2.) Next I had to turn the “malformed_frog_locations.csv Events” file to a shapefile by right clicking on it in the contents tab and clicking “data” then “export data”. I then clicked the “the data frame” button to use as coordinate system and selected the folder I wanted to save it in and named it “malformed_frog_locs.shp” and created it as a new layer and removed the events file.
3.) Next I wanted to separate all of the year 1 malfrog locations from the year 5 malfrog locations. To do this I did select by attribute and set the layer to “malformed_frog_locs”, method “create a new selection”, double clicked on “year_” clicked “=” and typed in 1. Then I pressed ok and all malfrog locations from year 1 were selected. I right clicked the “malformed_frog_locs” layer then clicked “selection” and “create new layer from selection” and renamed it “malformed_frog_locs_yr1”. I then redid these steps but with year 5 attributes instead of year 1 and renamed this new layer “malformed_frog_locs_yr5”.
4.) Now it is my job to isolate each malfrog location for each year and buffer zone and create separate shapefiles. To do this I first wanted to start with year one frogs in buffer zone 0.5. To start I did select by attribute and set the layer to “buffer_no_lakes”, method “create a new selection”, and the query reads ““distance”=0.5” and then I pressed ok. Next I used select by location and made the selection method “add to the currently selected features in” target layer “malformed_frog_locs_yr1” and source layer “buffer_no_lakes” (check “use selected features”) and set spatial selection method for target layer features “are completely within the source layer feature”. I now have all the malfrogs from year one that were located within the 0.5 buffer zone selected. I then right clicked on the “malformed_frog_locs_yr1” layer and went to “selection” then “create new layer from selection” and renamed the new layer “malformed_frog_locs_yr1_0-5”.
5.) Next I created a shapefile from the new layer by right clicking on “malformed_frog_locs_yr1_0-5” and going to “data” then “export data”. I clicked on “the data frame” for coordinates and saved it into the proper folder as “malformed_frog_locs_yr1_0-5.shp” and pressed ok and ok again to create a new layer. I then deleted the old layer.
6.) My next step was to find the nearest neighbor. With the features still selected I clicked on ArcToolbox  Analysis Tools  Proximity  Near. I put “malformed_frog_locs_yr1_0-5” as the input layer and as near features and pressed ok. Once that was completed I opened the attribute table for the “malformed_frog_locs_yr1_0-5” layer and right clicked on “near_dist” field and clicked statistics. I then wrote down the mean distance which was 145.16 meters.
7.) My next step was to create random points so I could calculate the NNR. To do this I cleared my selection then did select by attributes, set layer as “buffer_no_lakes” and set the query to “”distance”=0.5” to select a proximity for the random points. Then I clicked on the ArcToolbox  Data Management Tools Feature Class  Create Random Points. I then set the output location to the folder I wanted and set the output point feature class to “random_points_yr1_1” and the constraining feature class to “buffer_no_lakes” and then set the number of points to 62 and pressed ok.
8.) My next step was to find the nearest neighbor for the random points by repeating step 6 for “random_points_yr1_1”. The mean was 92.74 meters. To calculate the NNR for year 1 buffer 0.5 I then divided 145.16/92.74=1.56=Dispersed.



The problem comes in when I go to redo the process for each buffer zone, I get all the proper attributes selected and am back at step 5. As soon as i go to create the new shape file it says there was an error, it does not give an error number. No matter what I try it continues to give me an error. But if i save the session and reopen ArcMap it magically works again, until I finish step 8 and am back on stop 5 for the next shapefile I need to create, same thing in order to create the new shapefile I have to save the session and reopen ArcMaps. If anyone can please help me figure out what the problem is that would be very much helpful. Thank you.

Viewing all articles
Browse latest Browse all 2328

Trending Articles