Sha256: 36f8956657231866cdc39d18a8b9bce05bc0999add5a0402761b3e0fcd962ae5

Contents?: true

Size: 508 Bytes

Versions: 74

Compression:

Stored size: 508 Bytes

Contents

CensusRegion.class_eval do
  data_miner do
    schema Earth.database_options do
      integer  'number'
      string   'name'
    end
    
    import 'the U.S. Census Geographic Terms and Definitions',
           :url => 'http://www.census.gov/popest/geographic/codes02.csv',
           :skip => 9,
           :select => lambda { |row| row['Region'].to_i > 0 and row['Division'].to_s.strip == 'X'} do
      key   'number', :field_name => 'Region'
      store 'name', :field_name => 'Name'
    end
  end
end

Version data entries

74 entries across 74 versions & 2 rubygems

Version Path
earth-0.3.8 lib/earth/locality/census_region/data_miner.rb
earth-0.3.7 lib/earth/locality/census_region/data_miner.rb
earth-0.3.6 lib/earth/locality/census_region/data_miner.rb
earth-0.3.5 lib/earth/locality/census_region/data_miner.rb
earth-0.3.4 lib/earth/locality/census_region/data_miner.rb
earth-0.3.3 lib/earth/locality/census_region/data_miner.rb
earth-0.3.2 lib/earth/locality/census_region/data_miner.rb
earth-0.3.1 lib/earth/locality/census_region/data_miner.rb
earth-0.3.0 lib/earth/locality/census_region/data_miner.rb
earth-0.2.14 lib/earth/locality/census_region/data_miner.rb
earth-0.2.13 lib/earth/locality/census_region/data_miner.rb
earth-0.2.12 lib/earth/locality/census_region/data_miner.rb
earth-0.2.11 lib/earth/locality/census_region/data_miner.rb
earth-0.2.9 lib/earth/locality/census_region/data_miner.rb
earth-0.2.8 lib/earth/locality/census_region/data_miner.rb
earth-0.2.7 lib/earth/locality/census_region/data_miner.rb
earth-0.2.6 lib/earth/locality/census_region/data_miner.rb
earth-0.2.5 lib/earth/locality/census_region/data_miner.rb
earth-0.2.4 lib/earth/locality/census_region/data_miner.rb
earth-ruby19-0.2.3 lib/earth/locality/census_region/data_miner.rb