Tagged Questions
1
vote
1answer
106 views
Editing attribute tables using Python
I am new to Python, so sorry for such a trivial question. There is a shapefile (let's call it Structures.shp) and the script I'm writing needs to update the value of only one record in only one field ...
6
votes
2answers
145 views
Refresh open attribute table in ArcMap (arcpy)
I am running the Calculate Field GP tool from the arcpy in ArcMap. When a row value is updated, it does not show up untill I use the Reload Cache tool (Table Options > Reload Cache). How do I refresh ...
0
votes
0answers
117 views
Select record from table attributes in QGIS and Python
Can anyone tell how I can access to the attribute table of a shp and select a record from a specific row and column using Python (with console or a script). I've been looking for in the qgis API, but ...
8
votes
1answer
249 views
Fastest methods for modifying attribute tables with Python?
A while ago, I wrote a quick Python function for converting an attribute table to a python dictionary, where the key is taken from a user-specified unique ID field (typically the OID field). ...
2
votes
1answer
75 views
Updating and inserting a field within the same loop
I am working with an empty feature class where I am writing a script to create polylines within the featureclass and attach an associated text value with the polyline.
I am using a for loop as noted ...
1
vote
0answers
123 views
Morphometric and hydrological analysis with Python and ArcGIS
How can I write a program using python, that calculates some morphometric and drainage indexes using numeric attributes in the attribute table with ArcGIS?
The data I have in my table are area and ...
4
votes
1answer
91 views
convert a dbf into a raster image using python? work around for arcpy
ArcGIS' arcpy does not have a function to add a table to a layout. I was thinking that maybe taking that table (e.g. a dbf), there may be some python script command to turn it into a raster (e.g. do ...
4
votes
1answer
244 views
How to write values from arcpy statistical output to table?
The attached script is my stalled attempt to perform the following workflow:
Create a table and create fields
Loop through a folder of point shapefiles and perform average
nearest neighbor analysis
...
2
votes
3answers
458 views
Creating new shapefile based on its attributes with python
I have a shapefile which has an attribute year. I used to generally copy and paste these features in the dataframe and then using the definition query just show polygons which were established before ...
2
votes
1answer
262 views
How do I select * rows of multiple columns in one query using Select by Attributes within ArcMap?
I am trying to convert a psql query string into arcpy formatting for an UpdateCursor where expression parameter:
'''SELECT ...
7
votes
2answers
268 views
Python, GDAL and building raster attribute tables
I have an integer raster for which I would like to build a raster attribute table using Python and GDAL. I can create a GDAL raster attribute table in Python as follows:
>>> rat = ...
1
vote
1answer
806 views
ArcGIS 10.0 \ arcpy - CalculateField_management : help with syntax for updating text in attribute table of feature classes
I am trying to add (ie "Author", "LastUpdated") to feature classes within a gdb and then populate each of those fields. I have been able to get my code to run properly for the numerical field but I ...
4
votes
1answer
149 views
Python/GDAL get unique values in discrete-valued raster
I would like to get some advice on the most efficient way to return a list of unique values of a discrete-valued raster using Python and GDAL.
I had thought that the most obvious way would be to ...
0
votes
2answers
325 views
How to auto populate multiple fields in attribute table?
i have Feature Class Buildings, it has many fields like ...
4
votes
2answers
2k views
How to add automate values to attribute field?
I have parcel, Buildings layers, without any information attribute table, and i want to replace "NULL" values with numbers form 1 to 2000, in "Parcel ID", or "Building ID" field
thank you.