Index ¦ Archives ¦ Atom

List Comps

If I had to choose my single favorite programming idiom in Python, I wouldn't even need to pause to consider; hands down, it's list comprehensions. I use them all the time, and once you understand them, so will you. They are easy to, well, comprehend, and yet allow ...


ArcPy Documentation

Need a listing of the arcpy package? Here's how to write the documentation to a file:

import arcpy
import pydoc
out_file = r'c:\home\pydev\arcpy_docs.txt' 
strhelp = pydoc.plain(pydoc.render_doc(arcpy, "Help on %s"))
with open(out_file, 'w') as destination:
    destination.write(strhelp)

Two things about this ...

© Grant Miller-Francisco. Built using Pelican. Theme by Giulio Fidente on github.