754 questions
0
votes
1
answer
49
views
Filter mosaic dataset by date with arcpy
I am currently trying to create a python toolbox (atbx) in ArcGIS Pro (3.5) to compute a profile of mosaic dataset values. The tool takes a mosaic dataset and a line feature as inputs. The output is a ...
0
votes
0
answers
43
views
Arcpy manually assign class breaks
I want to have dynamic symbology by manually assigning values for class breaks:
≤ min
min - max
> max
I've come up with the function below, the issue is that it does not create the number of ...
0
votes
0
answers
36
views
Import of arcpy in R via reticulate fails with DLL load error
I've just installed ArcGIS Pro 3.5 on my Windows PC. I would like to use the arcpy Python library in R via the reticulate package, as I have done this successfully in the past.
For the sake of getting ...
0
votes
0
answers
29
views
How do I label unique polygon values in arcpy and store their colors?
I have a polygon layer with 10 features with unique IDs. I want to color them deterministically based on this unique ID values field and store the RGB values of their colors, like in a dictionary. ...
-1
votes
1
answer
134
views
Arcpy seems to not carry out my SQL clause
In the following code I meant to select rows from a table of cities named fc where the COUNTY='Socorro County' and ORDERED BY NAME:
fc="cities_copy"
where_selection=""""...
0
votes
0
answers
292
views
Why reticulate package is not working in R?
I am using reticulate package in R. I am trying to import arcpy using py_run_string (Python 3.9 version). Same code is working on my desktop. What can be the reason it is not working in my laptop?
...
0
votes
1
answer
84
views
Using ArcPy to set visibility range not working in ArcPro 2.8.8
I need to automate the configuration of properties for a large number of Feature Layers that are based on queries of a base Filegeodatabase in ArcPro version 2.8.8. The first part of the process has ...
0
votes
1
answer
57
views
assign rank and maintain sequence across duplicates
I'm assigning an incremental rank based on a value, but need to assign the same rank to duplicate values and maintain the overall sequence.
Instead of this:
Value
Rank
400
1
500
2
175
3
250
4
120
5
...
0
votes
1
answer
306
views
Understanding ArcPy's MakeFeatureLayer in order to edit data of a FeatureClass in ArcGIS Pro with a standalone script in VS Studio
I'm pretty new in ArcGIS and Arcpy, but experienced in Python. At the moment, I am working on an existing Python-Code in VS Studio (not my Code). I have some trouble understanding ArcPy's ...
0
votes
1
answer
38
views
Arcpy- How do I add a list of data onto a boundary
I have created code that averages the yearly data and creates a list of lists, like so:
[['1988', 0.09680851063829785, 1.2444680851063827], ['1989', 0.2046808510638298, 1.0231914893617025]]
I want to ...
0
votes
1
answer
23
views
Is there any reason why the arcpy.AddColormap_management(input_raster, colormap) line is not working in my code?
So I'm trying to code a population density map for the state of Alabama using arcpy, and I have an output .tif file that shows the population density, the only issue is that it's in grayscale and I ...
0
votes
0
answers
84
views
Error in ArcPro's Fill Missing Values Tool using arcpy in Python
Fill Missing Values Tool runs perfectly fine in ArcPro, but when attempting to do the same in Python using arcpy module, it returns an error. The error message indicates a problem within the internal ...
0
votes
0
answers
40
views
running a script on an entire folder
I am more familiar with R, and I haven't written scripts for a couple years due to a job change so any help would be greatly appreciated.
I have the following script that will list the feature ...
0
votes
1
answer
316
views
Reclassify a feature class with arcpy using Natural Breaks (Jenks) method
I'm trying to reclassify a feature class using arcpy, but the Python functionality for the Reclassify tool doesn't appear to be the same as the Dialog functionality. The tool dialog gives you the ...
0
votes
2
answers
488
views
How can I extract the 'Pixel Depth' of a raster as a value using Model Builder in ArcGIS Pro (or evt. a python script)
In ArcGIS Pro I want to automate some tests on rasters, either stored in .gdb- or .tiff-files.
One of the tests requires checking the Pixel Type and Pixel Depth of the raster (has to be floating point ...
0
votes
0
answers
56
views
How to ignore python warning messages in Arcmap?
I want to calculate the OD Cost Matrix in ArcMap 10.3.1 using the arcpy package. When running the arcpy.Solve_na, the Python console prints a lot of warning messages. After a while, ArcMap crashes, ...
2
votes
1
answer
363
views
"management" is not a known member of module "arcpy" Pylance(report GeneralTypeIssues)
I am new to using vscode with python.exe for arcgispro. My interpreter is set to the arcgispro-py3-env\python.exe.
I would like to be able to run python code within vscode but I am running into some ...
0
votes
1
answer
288
views
Arcpy Error while running script, ERROR 000358: Invalid expression
import arcpy
arcpy.env.workspace = r"E:\Reserach\Dengu\Python"
arcpy.env.overwriteOutput = True
input_thana_shapefile = r"E:\Reserach\Dengu\New GIS Data\Dhaka_Thana.shp"
...
-1
votes
1
answer
204
views
Can't get arcpy.management.Rename to run
I'm trying to write a script where users can build the feature class name that aligns with our standards by selecting values. everything else in this script seems to work fine (you can print layername ...
0
votes
1
answer
617
views
How can I make it so my symbology updates when new data is entered into a field in Arcgis Field Maps?
I am working on a project where we have a line feature layer with empty fields that will be filled via data collectors using Arcgis Field Maps. The symbology just shows a black line for all the ...
0
votes
3
answers
1k
views
How to convert Extent, Scale and RefreshView from ArcMap to ArcPro using Python
I used an Python (2.7) ArcMap script for years and now I am trying to convert it to use with ArcPro (Python 3). I have converted half of my ArcMap script to ArcPro (with Visual Studio) but am stuck on ...
0
votes
1
answer
157
views
Arcpy codeblock returns Syntax Error on arcpy.da.SearchCursor
I have a file geodatabase in ArcGIS with a list of parking transactions that include start and end time, and a zone. I want to calculate a field in each row that gives the occupancy in that ...
0
votes
1
answer
330
views
How to program ArcGIS Pro 'vary symbology size by field' in arcpy
Is there a way to code in arcpy Vary symbology by attribute and the Size option. I have a field in a point file that has values for the size, which can be done manually in the Symbology tab, but I ...
0
votes
1
answer
263
views
Export pandas DataFrame to csv file using ArcGIS Pro script tool
I've created a script tool in ArcGIS Pro that asks the user to select a csv file, and then reads that csv file into a pandas DataFrame and performs some calculations. I'd like to be able to export a ...
0
votes
1
answer
582
views
Parameter drop down menu
Currently trying to create a Select by Attributes tool. However, I can not get my "Field Value" parameter to have a drop down menu where I can select the values within the field.
I have ...