This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Utah Street Address Locator (Geocoding) Service | |
# AGRC, 20130329 | |
# WHAT? | |
# Geocodes an input table in one of the arcgis-compatible file formats and produces | |
# an new output .csv table with the geocoded results | |
# IMPORTANT NOTES: | |
# | |
# individualized api key will be required in near future, here's how to get one: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import arcpy | |
import os | |
from os import listdir | |
import csv | |
def find_csv_filenames( path_to_dir, suffix=".csv" ): | |
filenames = listdir(path_to_dir) | |
return [ filename for filename in filenames if filename.endswith( suffix ) ] | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import arcpy | |
import csv | |
from arcpy import da | |
arcpy.env.overwriteOutput = True | |
bbRound= '8' | |
bbGeodatabaseLocation = r'Database Connections\ubbadmin@ubbmap@gdb10.agrc.utah.gov.sde' | |
##bbGeodatabaseLocation = r'I:\PROJECTS\Broadband\Round2 Submission\UT_SBDD_20101011.gdb\NATL_Broadband_Map' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Utah Street Address Locator (Geocoding) Service | |
# AGRC, 20131220 | |
# WHAT? | |
# Geocodes an input table in one of the arcgis-compatible file formats and produces | |
# an new output .csv table with the geocoded results | |
# IMPORTANT NOTES: | |
# | |
# individualized api key will be required in near future, here's how to get one: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#20120725_15:23pm | |
#working but in need of future refactoring (ex. change .bat to .py?) | |
#Runs off a locally stored .txt file containing JSON objects | |
#Writes zipped statewide gdb and shp data to outputRoot | |
#Writes .bat file with time stamp for replacing existing ftp site content | |
# jsonPackagesfile is a JSON data structure containing package objects. Each data package object | |
# consists of: | |
# ["Name"] the output name for the package, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import arcpy | |
arcpy.env.overwriteOutput = True | |
def fcUpdate(srcTable, tarTable): | |
tarTableView = arcpy.MakeTableView_management(tarTable,'targetTable') | |
srcTableView = arcpy.MakeTableView_management(srcTable,'sourceTable') | |
arcpy.DeleteRows_management(tarTableView) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import urllib2 | |
import datetime | |
from time import strftime | |
def getEconomicScore(inMedianHouseholdIncome): | |
#Set this variable from: | |
#http://www.census.gov/hhes/www/income/data/historical/household/2010/H08_2010.xls | |
#This data would make a nice web service! |