POST
|
One year and a few months later, and I still can't get the data to plot. Can anyone offer any insights?
... View more
04-12-2021
10:23 AM
|
0
|
0
|
723
|
POST
|
@Mary_Murphy both of the input layers are stored locally.
... View more
04-05-2021
08:38 AM
|
0
|
3
|
3158
|
POST
|
Hey @JayantaPoddar , I tried both of your suggestions but there is still no output generated from the tool. There were a few new features generated from the multipart to singlepart too. I just ended up using a work around. I created a new attribute in the census data called 'full_tract_area'. I then did an intersect with my polygon layer and the census data. I then calculated new attributes of interest using the proportion of tract in the new layer. For example: 'carpooled_updated' = ('shape_area' / 'full_tract_area') * 'carpooled_original' This was a little more manual than I was hoping for. But thanks for all your help on this. I really appreciate it.
... View more
03-31-2021
07:38 AM
|
1
|
0
|
3196
|
POST
|
I also tried creating a new polygon feature class to act as my Input Polygon to summarize the Census data within and still the same results.
... View more
03-31-2021
06:06 AM
|
0
|
7
|
3169
|
POST
|
@Mary_Murphy , the grouping field, 'County' is a text field. I also tried running the tool without passing a field to the GroupBy argument and I'm still not getting any results.
... View more
03-31-2021
06:00 AM
|
0
|
8
|
3169
|
POST
|
I'm having trouble getting the data down to size. I'm wrapping up things for the day here but I'll try again tomorrow. Thanks for all your help.
... View more
03-30-2021
01:37 PM
|
0
|
0
|
3217
|
POST
|
@JayantaPoddar I have tried those steps and the issue still persists. I appreciate your suggestions.
... View more
03-30-2021
12:29 PM
|
0
|
0
|
3237
|
POST
|
@JayantaPoddar I've edited the post to include the screenshots.
... View more
03-30-2021
12:10 PM
|
0
|
0
|
3282
|
POST
|
I am trying to run the tool Summarize Within (Analysis tool) in ArcGIS Pro 2.7.2. The tool successfully runs but does not return a new layer or table. I can open the Details pane and see that the output locations are correct. But when I look in the project geodatabase, there is nothing there. The data I'm using for the input polygon is a single feature that covers several counties. The input summary features is a polygon layer of census tracts. I am trying to sum several of the attributes and use the group by function to group by county. Both data layers are in the same projection, epsg: 4269. I have been able to run other tools, buffer, intersect, etc and they all return the expected outputs. Has anyone else experienced something similar?
... View more
03-30-2021
11:48 AM
|
1
|
25
|
7680
|
POST
|
I have created a custom Arcade expression for a layer's symbology based on two attribute fields, Land Use and Revised Land Use. If the Revised Land Use field is empty, then symbolize the parcel based on the Land Use field but if the Revised Land Use is not empty, then symbolize the parcel based on that field. The two attributes share the same coded domains of 28 possible values. The layer contains parcel data for the entire county so there are approximately 300,000 parcels. My issue is that when ArcGIS Online generates symbology based on the custom expression, it only samples a subset of the data and does not return the full list of possible values. My question is how do I get ArcGIS Online to sample the full dataset so that I can configure the symbology for all possible values? I have read this post but the solution presented is not ideal. Can anyone point me in the right direction? Thanks, Miguel Fernandez
... View more
01-06-2021
07:29 AM
|
1
|
2
|
800
|
POST
|
Dan_Patterson , I feel quite foolish now because after digging into this a little deeper, I realized I was using the alias instead of the field name. Normally, that would not be a problem but because I joined two tables together, it placed the table name in front of the field name. I was able to go in an add the correct field name with the table name in front of it and everything ran fine. Thanks for working on this with me. -Miguel
... View more
01-23-2020
08:26 AM
|
0
|
1
|
3037
|
POST
|
I was missing that ! mark in the code I pasted here, but with that correction I still receive the same error.
... View more
01-23-2020
08:00 AM
|
0
|
3
|
3037
|
POST
|
I am trying to write a Python script that adds several fields to a feature class and then calculates those new fields. This is a process I will have to do to multiple layers so I am hoping to automate this. I am using ArcGIS Pro 2.4.3 and Python 3.7. I have the following script: # Import system modules
import arcpy
# Set environment settings
arcpy.env.workspace = r"D:\Project Data\System Analysis\Jan 2020\Sys_analysis_2020\Sys_analysis_2020.gdb"
table = "single_market_area_no_urban_working_intersect"
# Add Fields
arcpy.AddField_management(in_table=table,
field_name="total_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="white_only_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="no_vehicle_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="under18_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="over65_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="poverty_pop_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="total_hh_intersect",
field_type="SHORT")
arcpy.AddField_management(in_table=table,
field_name="minority_pop_intersect",
field_type="SHORT")
# Calculate newly added fields
arcpy.CalculateFields_management(in_table=table,
expression_type="PYTHON3",
fields=[["total_pop_intersect", "!total_pop* (!Shape_Area!/!tract_area!)"],
["white_only_pop_intersect", "!white_only_pop! * (!Shape_Area!/!tract_area!)"],
["no_vehicle_pop_intersect", "!no_vehicle_pop! * (!Shape_Area!/!tract_area!)"],
["under18_pop_intersect", '!under18_pop! * (!Shape_Area!/!tract_area!)'],
["over65_pop_intersect", "!65over_pop! * (!Shape_Area!/!tract_area!)"],
["poverty_pop_intersect", "!poverty_pop! * (!Shape_Area!/!tract_area!)"],
["total_hh_intersect", "!total_households! * (!Shape_Area!/!tract_area!)"],
["minority_pop_intersect", "!minority_pop! * (!Shape_Area!/!tract_area!)"]]) When I run the code above, I receive multiple lines of error messages: Traceback (most recent call last):
File "<string>", line 44, in <module>
File "c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py", line 4265, in CalculateFields
raise e
File "c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py", line 4262, in CalculateFields
retval = convertArcObjectToPythonObject(gp.CalculateFields_management(*gp_fixargs((in_table, expression_type, fields, code_block), True)))
File "c:\program files\arcgis\pro\Resources\arcpy\arcpy\geoprocessing\_base.py", line 506, in <lambda>
return lambda *args: val(*gp_fixargs(args, True))
arcgisscripting.ExecuteError: ERROR 000539: Invalid field total_pop
ERROR 000539: Invalid field white_only_pop
ERROR 000539: Invalid field no_vehicle_pop
ERROR 000539: Invalid field under18_pop
ERROR 000539: Invalid field 65over_pop
ERROR 000539: Invalid field poverty_pop
ERROR 000539: Invalid field total_households
ERROR 000539: Invalid field minority_pop
ERROR 000539: File "<expression>", line 1
* (/1)
^
IndentationError: unexpected indent
ERROR 000539: File "<expression>", line 1
* (/2)
^
IndentationError: unexpected indent
ERROR 000539: File "<expression>", line 1
* (/3)
^
IndentationError: unexpected indent
ERROR 000539: File "<expression>", line 1
* (/4)
^
IndentationError: unexpected indent
ERROR 000539: File "<expression>", line 1
* (/5) The error message goes on like that for 1000 lines. I have been able to run the first half the code by itself and create the new fields with no errors. When I try to run the last half by itself, I receive the same error message as above. I have tried to just calculate one field using Python and I still receive the same error. arcpy.CalculateFields_management(in_table=table, expression_type="PYTHON3",
fields=[["total_pop_intersect", "!total_pop! * (!Shape_Area!/!tract_area!)"]]) Where am I going wrong? Any guidance would be appreciated.
... View more
01-23-2020
07:53 AM
|
0
|
6
|
3262
|
POST
|
I'm pulling data from an API and viewing it in a pandas dataframe using a Jupyter Notebook. The data has several attributes including latitude and longitude. I can successfully convert the pandas dataframe to a spatially enabled dataframe, call the .head() method and see the new SHAPE column. I can create a map object but when I try to plot my dataframe on the map object, the map does not update and display the points. I've included my code below: # Define parameters for API call
headers = {
'accept': 'application/json',
'Api-Token': 'Key',
'Agency-ID': 'ID'
}
# Call API and save to a varialbe
response = requests.get('URL', headers=headers).json()
# Convert json to dataframe
df = pd.DataFrame(response)
# Convert dataframe to spatially enabled dataframe
df = pd.DataFrame.spatial.from_xy(df, x_column = 'longitude', y_column = 'latitude')
# Create map object and display map
gis = GIS()
m = GIS().map()
m.center = [36.081179, -79.556955]
m.zoom = 9
m
# Plot dataframe
df.spatial.plot(map_widget= m) Line 22 returns a map and Line 25 returns 'True' but no updates to the map are made. I've also tried using the renderer and symbol_type and symbol_style attributes. df.spatial.plot(map_widget=m,
symbol_type='simple',
symbol_style='d', # d - for diamonds
colors='Reds_r',
cstep=10,
outline_color='Blues',
marker_size=10) This block of code replaced Line 25 in the first section but did not display in the map either. I've been through the documentation and the guide on GitHub but cannot find anything to make it work. Please advise. Thanks, Miguel Fernandez
... View more
01-07-2020
02:08 PM
|
0
|
2
|
984
|
Title | Kudos | Posted |
---|---|---|
1 | 10-18-2019 07:29 AM | |
1 | 03-30-2021 11:48 AM | |
1 | 03-31-2021 07:38 AM | |
1 | 01-06-2021 07:29 AM | |
1 | 12-04-2018 05:29 AM |
Online Status |
Offline
|
Date Last Visited |
06-07-2021
03:15 PM
|