|
POST
|
Data needs to be structured so that coords for point 1 are starting Lat_S and Lon_S and point 2 coords are Lat_E and Lon_E. INDEX LOCAL_DATE LOCAL_TIME LATITUDE_S LONGITUDE_S LATITUDE_E LONGITUDE_E 1 9/27/2013 8:24:34 46.299584 -105.973519 46.299511 -105.973503 2 9/27/2013 8:25:34 46.299511 -105.973503 46.299497 -105.973463 3 9/27/2013 8:26:34 46.299497 -105.973463 46.299497 -105.973463 You need to connect from one point to the next and double up your last coord to end the connections. Start X = Lon_S Start Y = Lat_S End X = Lon_E End Y = Lat_E Even those these tools should work with CSV or Tables in GDB I have found the odd instance where just using a CSV file and creating a shapefile will work as opposed to creating or using files within the GDB.
... View more
03-18-2014
03:22 PM
|
0
|
0
|
6067
|
|
POST
|
Sounds like font substitution from PDF end of process. Under the Format tab to export to PDF are you clicking the Embed All Document Fonts? If you are using the python ExportToPDF I think there is a setting/option to embed fonts as well. Regards, Craig
... View more
03-17-2014
02:40 PM
|
0
|
0
|
674
|
|
POST
|
ArcToolbox > Analysis Tools > Overlay > Spatial Join: Set the following: Join operation > Join_One_To_Many. Match option > Intersect.
... View more
03-02-2014
12:35 PM
|
0
|
0
|
917
|
|
POST
|
There was a recent posting on an ESRI forum about a 'sector analysis' tool. If you can get the bearing of your upstream segment, you might be able to use it to automate some of this process. http://mappingcenter.esri.com/index.cfm?fa=arcgisResources.modelsScripts Regards, Craig
... View more
02-27-2014
01:00 PM
|
0
|
0
|
2809
|
|
POST
|
If you only have 6 combinations, I suggest making a custom style with a polygon fill colour and a different form of hatching over your colours. Create a concatenated field or a 'class / category' field that you can name and apply your custom style to match. Can you give an example of your data combinations. Regards, Craig
... View more
02-03-2014
01:18 PM
|
0
|
0
|
1291
|
|
POST
|
Hi Caleb, That looks very promising. Will be trying it. Is the list auto-populated into a tool when script is imported into ArcToolbox or do properties need setting? The on-line help doesn't make things real clear. Regards, Craig
... View more
01-21-2014
06:34 PM
|
0
|
0
|
1729
|
|
POST
|
Hi, I am using GetParameterAsText. I want to be able to select a value (i.e. A or B) for my response from a prompted list. How can I code a prompt list to appear with set values? Is this possible within ArcPy without having to use an add-in? Regards, C. Poynter
... View more
01-16-2014
05:39 PM
|
0
|
3
|
3354
|
|
POST
|
Just an idea, but have you tried using scale ranges, so that when you zoom to a floor level only it's labels turns on and everything else turns off, even if all floors are displayed. Regards, Craig
... View more
12-01-2013
12:31 PM
|
0
|
0
|
1739
|
|
POST
|
This post may help: http://support.esri.com/fr/knowledgebase/techarticles/detail/14910 Regards, Craig
... View more
10-21-2013
05:44 PM
|
0
|
0
|
2298
|
|
POST
|
Sounds like a font substitution issue. You may have to put your software disc in again and do a Repair. Regards, Craig
... View more
10-21-2013
01:56 PM
|
0
|
0
|
2298
|
|
POST
|
Look at using "points to line" tool. Then create points using "vertices to point" tool. You will need to calculate how long cow was at each point for time spent at each point. Time sampling period is going to be an issue. As cows may move location, but the movement isn't picked up (i.e. they will just be found at a new location without a 'speed' of movement). Resolution of data can be an issue. In your sample over 2 minutes the cows moved 3 times but only once over a distance of 8m Is there an option to filter data? Regards, Craig
... View more
10-20-2013
03:21 PM
|
0
|
0
|
6067
|
|
POST
|
You will need to access the "TEXT_ELEMENT" or elements as you have three using arcpy. Basis included here for a single element and a single featureclass.
import arcpy
fc = r"D:\Data.shp"
fieldList = [f.name for f in arcpy.ListFields(fc, "*")]
for field in fieldList:
queryStr = "\"" + field + "\" > 0"
mxd = arcpy.mapping.MapDocument(r"D:\MyMXD.mxd")
elm = arcpy.mapping.ListLayoutElements(mxd, "TEXT_ELEMENT")[0]
elm.text = "Title or something: " + field
df = arcpy.mapping.ListDataFrames(mxd, "Layers")[0]
for lyr in arcpy.mapping.ListLayers(mxd, "", df):
if lyr.name == "Data":
if lyr.supports("DEFINITIONQUERY"):
lyr.definitionQuery = queryStr
arcpy.RefreshActiveView()
arcpy.mapping.ExportToPDF(mxd, r"D:\Data" + "\\" + field + ".pdf")
del mxd
This pulls the field names and applies the "DEFINITIONQUERY" to the data, but might be adaptable to pulling attributes. Regards, Craig p.s. If applying "DEFINITIONQUERY" to multiple FCs with same attribute values consider:
for value in uniqueValues:
queryStr = "\"" + field + "\" = '" + str(value) + "'"
df = arcpy.mapping.ListDataFrames(mxd, "Layers")[0]
for lyr in arcpy.mapping.ListLayers(mxd, "", df):
if lyr.name == "FC1" or lyr.name == "FC2" or lyr.name == "FC3":
lyr.definitionQuery = queryStr
... View more
10-17-2013
08:43 PM
|
0
|
0
|
1005
|
|
POST
|
Without testing it myself, try:
import arcpy
from arcpy import env
from arcpy.sa import *
arcpy.CheckOutExtension("Spatial")
env.workspace =
srcFC =
cellSize =
power =
searchRadius =
tbl= arcpy.ListFields(srcFC, 'r*')
for zField in tbl:
print 'Processing: ' + zField
outIDW = Idw(srcFC, zField, cellSize, power, searchRadius)
outIDW.save(env.workspace + '\\' + zField + '_IDW')
del srcFC, cellSize, power, searchRadius, tbl, zField
You will need to set your input workspace, source featureclass, cellsize, power, radius. You will need to have a look at the 10.2 Help reference to IDW, so you can identify which Radius method you wish to utilise. What I have given here is a basis for development, which needs to be polished and finished to run for your application. If it doesn't run in IDLE, run from within Python GUI in ArcGIS or ArcCatalog. Regards, Craig
... View more
09-22-2013
08:25 PM
|
0
|
0
|
2491
|
|
POST
|
The critical part you need to manipulate is the field names. Access to these can be achieved using:
import arcpy
tbl= arcpy.ListFields(r'D:\Temp\Test.mdb\Test')
for fld_names in tbl:
print fld_names.name
or
import arcpy
tbl = r'D:\Temp\Test.mdb\Test'
fld_names = [f.name for f in arcpy.ListFields(tbl)]
print fld_names
Second method many by more ideal for iterating in a script, as field names are stored in a python list/table. Regards, Craig
... View more
09-22-2013
03:54 PM
|
0
|
0
|
2491
|
|
POST
|
Hi Steve, I have pulled the relevant code for you that I eventually sorted out. You might need to play with it a little to get what you require.
fh = open(r'D:\Temp\CSD_HTML\CSD_QandA.html', 'wb')
html_head = """
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title></title>
</head>"""
fh.write(html_head)
html_body = """
<body>
<table width="799" height="317" border="0" cellspacing="1">
<tr>
<td width="309" rowspan="5"><img src="Thumbs/""" + nm + """.jpg" alt="" width="300" height="300" align="left"></td>
<td width="4" rowspan="5"> </td>
<td height="50" colspan="3">Title: """ + title + """</td>
</tr>
</table>
</body>"""
fh.write(html_body)
html_tail = """
</html>"""
fh.write(html_tail)
fh.close()
del fh
I broke it up into 3 sections, head, body and tail. The body section is where you can play around with adding thumbnail and other information. I designed my webpage first and then copied and modified the HTML code for use within my script. Regards, Craig
... View more
09-18-2013
03:25 PM
|
0
|
0
|
886
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 06-22-2014 03:26 PM | |
| 1 | 11-03-2022 03:28 PM | |
| 1 | 05-24-2021 05:01 PM | |
| 1 | 12-02-2019 02:46 PM | |
| 3 | 11-01-2020 07:20 PM |
| Online Status |
Offline
|
| Date Last Visited |
06-04-2025
09:55 PM
|