Tag Info

New answers tagged

2

You may use the Merge tool: Combines multiple input datasets of the same data type into a single, new output dataset. This tool can combine point, line, or polygon feature classes or tables. Open you model drag in the Merge tool, double click on in and add the many gdb tables within the input parameter, define out name and location, and then save ...


1

After you have added the shapefile, take a look at Rightclick -> SET CRS for Layer. The layer CRS should be either EPSG:102711, or a custom CRS with these parameters: +proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +datum=NAD83 +units=us-ft +no_defs You can enable on-the-fly-reprojection, set the project CRS to EPSG:3857, ...


0

It should be the problem that @Jake mentioned. When adding a CSV layer you are creating a temporary layer which do not alter the default on-the-fly CRS (i.e. WGS-84). When adding the shapefile with a different CRS, you do however alter the on-the-fly CRS to NAD1983, which shift and/or distort your original temporary data. Two things you may do: Export ...


0

Since you're using ArcGIS 10.2, you can take advantage of the new SearchCursor in the Data Access module, which returns row values in the order of the fields specified. Try replacing your current cursor code with: #--now we make the search cursor that will iterate through the rows of the table for row in arcpy.da.SearchCursor(genStruct, fieldList): ...


1

Here is a script to turn your csv into a keyed object as suggested in the comments: function csvJSON(csv){ var lines=csv.split("\n"); var result = {}; var headers=lines[0].split(","); // start at 1 to skip the header row for(var i=1;i<lines.length;i++){ var obj = {}; var currentline=lines[i].split(","); var key = currentline[0]; ...


0

I have by chance this morning discovered a secondary answer to this question which I've not seen mentioned anywhere, and which seems worth a full description. The CSV file is loaded into QGIS in the normal way (using the button for doing this). Then this can be saved as (right click the layer entry and 'Save as...') an ESRI Shapefile. This produces a couple ...


1

Use the MMQGIS plugin's "Attributes Join from CSV File" method. I have a shapefile called postcodes with just the postcode attribute, and a CSV file called people.csv with a name and a postcode column. I load the postcode shapefile into QGIS (but not the CSV). Then MMQGIS: Combine: Attributes Join From CSV File and fill the dialog thus: That gives me a ...


2

Currently the best solution to read, work on and write csv files is the pandas module. Read a csv file (an example) import pandas as pd df = pd.read_csv("test.csv") print df type long lat o x y z t 0 AREA 44.37 -0.83 5 1 NaN NaN KKO 1 AREA NaN NaN 5 1 8 3 KKO 2 AREA 46.48 -0.85 NaN NaN NaN NaN KKO 3 AREA ...


0

In Mac OS X Excel, save as "Windows CSV" instead of the Mac CSV option and Add Delimited Layer should now recognize the data



Top 50 recent answers are included