Michael Orlitzky [Mon, 16 Nov 2009 01:38:05 +0000 (20:38 -0500)]
Modified the default_option_parser function to return a parser using a VerbatimHelpFormatter.
Updated the scripts using default_option_parser to account for the whitespace changes.
Michael Orlitzky [Mon, 16 Nov 2009 01:26:15 +0000 (20:26 -0500)]
Added an LEHD module, with classes to parse Origin-Destination matrix files.
Added tests and fixtures for the LEHD module.
Updated the run_tests script to include the new LEHD tests.
Michael Orlitzky [Fri, 13 Nov 2009 02:21:15 +0000 (21:21 -0500)]
Moved the multiple-filename logic inside the find_file_paths function.
Added tests for the FileUtils module, and in particular for the find_file_paths function.
Added two fixtures for the new tests.
Updated the test suite.
Michael Orlitzky [Wed, 11 Nov 2009 04:35:07 +0000 (23:35 -0500)]
Removed rows length checks in two places, and replaced them with first-column-not-None checks.
Removed an unnecessary conditional from get_block_geometry_as_wkt().
Added styles for blockquotes and regular quotes (<q> elements).
Changed some of the reset styles to use 'inherit' since we don't have to worry about Internet Explorer screwing them up.
Michael Orlitzky [Mon, 19 Oct 2009 14:17:02 +0000 (10:17 -0400)]
Updated the KML classes with a print_kml() method.
Abstracted the to_kml() and print_kml() methods out in to the KmlObject class for most subclasses.
Modified pg2kml to use the print_kml() method instead of to_kml().
Michael Orlitzky [Mon, 19 Oct 2009 11:51:40 +0000 (07:51 -0400)]
Added a unique index on the tiger_lines "tlid" column.
Created a quick sed script to filter "BEGIN;" and "END;" from the shp2pgsql output.
Updated the makefile to import the tiger_lines data one row at a time, outside of a transaction.
Added a new script, download_data, to aid in the retrieval of the census data.
Moved the 'all lines' data retrieval out of the makefile and in to the new script (currently: D.C., MD, PA only).
Added the MD lines import to the makefile.
Reworked the data target to be more modular.
Made the blocks/lines import via wildcard.
Fixed all of the index/append inconsistencies in the shp2pgsql usage.
Added the D.C. blocks download/import.
Created a tiger_lines task initially handling only the D.C. lines.
Added URLs for all of the MD county all-lines shapefiles.
Updated the makefile to import TIGER block data for MD, VA, PA, and NY.
Removed quotes from some makefile variables.
Redirected psql output to /dev/null.
Renamed the "tiger" table to "tiger_blocks" in preparation for the addition of the TIGER road data.
Shortened the name of the "tiger_blkidfp00" method/column to just "blkidfp00".
Michael Orlitzky [Mon, 28 Sep 2009 02:24:12 +0000 (22:24 -0400)]
Added unit tests for the Census.Database class.
Created a new method in the Census.Database class for testing.
Updated the test script with the new suite.
Michael Orlitzky [Wed, 16 Sep 2009 03:16:43 +0000 (23:16 -0400)]
Modified find_avg_population_density to perform a GIS database query.
Added optparse argument parsing so that database information does not need to be hard-coded in to the script.
Switched the order of (longitude, latitude) in the arguments.
Michael Orlitzky [Sat, 12 Sep 2009 17:41:20 +0000 (13:41 -0400)]
Added the framework for the PostGIS database integration.
Created makefile targets for the Tiger data and census database.
Added comments to the makefile describing the targets.
Created a SQL script to create the sf1_blocks table, and to add indexes on both blkidfp00 columns.
Created a new script, sf1blocks2sql (used by the makefile), which exports the Summary File 1 blocks as SQL "INSERT" statements.
Michael Orlitzky [Sat, 12 Sep 2009 14:55:14 +0000 (10:55 -0400)]
Added state, county, and tract fields to the Block class.
Renamed the other Block attributes to follow the GeoRecord/Tiger naming convention.
Updated any tests/methods that depended on the Block attribute names.
Throw an error from within the Block class if the "block" attribute is non-integral.
Michael Orlitzky [Sat, 12 Sep 2009 14:48:25 +0000 (10:48 -0400)]
Added the StringUtils module with the is_integer() function.
Imported StringUtils into SummaryFile1.
Removed the InvalidAreaError, since we need to accept areas of zero.