cleaned code more, encapsulated some stuff, got column titles to convert properly