Skip to content

Instantly share code, notes, and snippets.

@ryan-hill
ryan-hill / dbf2DF.py
Last active July 3, 2023 16:09
Import DBF file to Pandas data frame in Python
import pysal as ps
import pandas as pd
'''
Arguments
---------
dbfile : DBF file - Input to be imported
upper : Condition - If true, make column heads upper case
'''
def dbf2DF(dbfile, upper=True): #Reads in DBF files and returns Pandas DF
db = ps.open(dbfile) #Pysal to open DBF
@clhenrick
clhenrick / README.md
Last active April 1, 2024 14:55
PostgreSQL & PostGIS cheatsheet (a work in progress)