Sha256: ac4f7f22c31693cc2a64778336f9791001a67c9f76160a552916cf82edf09de1
Contents?: true
Size: 908 Bytes
Versions: 8
Compression:
Stored size: 908 Bytes
Contents
CountryRailClass.class_eval do data_miner do import "a list of country-specific rail classes and their pre-calculated characteristics", :url => 'https://docs.google.com/spreadsheet/pub?key=0AoQJbWqPrREqdFg3YVptS2FYdHBsb2kyZFRxSm5FdlE&output=csv' do key 'name', :synthesize => proc { |record| [record['country_iso_3166_code'], record['rail_class_name']].join(' ') } store 'country_iso_3166_code' store 'rail_class_name' store 'passengers' store 'speed', :units_field_name => 'speed_units' store 'trip_distance', :units_field_name => 'trip_distance_units' store 'electricity_intensity', :units_field_name => 'electricity_intensity_units' store 'diesel_intensity', :units_field_name => 'diesel_intensity_units' store 'co2_emission_factor', :units_field_name => 'co2_emission_factor_units' end end end
Version data entries
8 entries across 8 versions & 1 rubygems