CartoDB / data-services

CARTO internal geocoder PostgreSQL extension
25 stars 11 forks source link

GBR postal codes were POINTs not POLYGONS! #51

Closed andrewxhill closed 9 years ago

andrewxhill commented 10 years ago

Can you check if you just grabbed the wrong source file? I've commented the table out of the build script for now.

https://github.com/CartoDB/data-services/blob/master/geocoder/postal-codes/sql/build_data_table.sql#L16

iriberri commented 10 years ago

@andrewxhill absolutely, they're points:

https://geocoding.cartodb.com/tables/uk_postcodes

There's not a dataset in the geocoding account for UK polygons.

andrewxhill commented 10 years ago

okay, then we need to leave GBR out of the polygon geocoder :)

you can double check that the data here, http://www.ons.gov.uk/ons/guide-method/geography/products/postcode-directories/-nspp-/index.html

might be okay to use. not sure if the gbr or the ireland portion only is licensed for non-business only

iriberri commented 10 years ago

The northern Ireland portion is just for personal or internal business use.

Under the terms of the Open Government Licence (OGL) and UK Government Licensing Framework (launched 30 September 2010), anyone wishing to use or re-use ONS material, whether commercially or privately, may do so freely without a specific application for a licence, subject to the conditions of the OGL and the Framework. Users reproducing ONS content must include a source accreditation to ONS.

Postcode products (including postcode lookups)

ONS postcode products (derived from CodePoint Open) are subject to the Open Government Licence(http://www.ordnancesurvey.co.uk/docs/licences/os-opendata-licence.pdf), and Ordnance Survey OpenData Licence.

For those who also use the Northern Ireland data (postcodes starting with "BT"), a separate licence for commercial use is required direct from Land and Property Services. An End User licence (for internal business use only) will be issued by ONS with the data. To download a copy, go to the 'Download' section of this page. Use of the Northern Ireland data contained within the ONS postcode products constitutes acceptance of the Northern Ireland licensing terms and conditions.

This copy says: image

Open Government Licence says: (http://www.ordnancesurvey.co.uk/docs/licences/os-opendata-licence.pdf)

You are free to: copy, publish, distribute and transmit the Information; adapt the Information; exploit the Information commercially and non-commercially for example, by combining it with other Information, or by including it in your own product or application.

andrewxhill commented 10 years ago

cool, so can you look into adding all except the norther ire?

On Wed, Aug 27, 2014 at 7:07 AM, Carla notifications@github.com wrote:

The northern Ireland portion is just for personal or internal business use.

Under the terms of the Open Government Licence (OGL) and UK Government Licensing Framework (launched 30 September 2010), anyone wishing to use or re-use ONS material, whether commercially or privately, may do so freely without a specific application for a licence, subject to the conditions of the OGL and the Framework. Users reproducing ONS content must include a source accreditation to ONS.

Postcode products (including postcode lookups)

ONS postcode products (derived from CodePoint Open) are subject to the Open Government Licence( http://www.ordnancesurvey.co.uk/docs/licences/os-opendata-licence.pdf), and Ordnance Survey OpenData Licence.

For those who also use the Northern Ireland data (postcodes starting with "BT"), a separate licence for commercial use is required direct from Land and Property Services. An End User licence (for internal business use only) will be issued by ONS with the data. To download a copy, go to the 'Download' section of this page. Use of the Northern Ireland data contained within the ONS postcode products constitutes acceptance of the Northern Ireland licensing terms and conditions.

This copy says: [image: image] https://cloud.githubusercontent.com/assets/1730320/4058741/31c7acee-2dda-11e4-83eb-3f4d9ac9fc20.png

Open Government Licence says: ( http://www.ordnancesurvey.co.uk/docs/licences/os-opendata-licence.pdf)

You are free to: copy, publish, distribute and transmit the Information; adapt the Information;

exploit the Information commercially and non-commercially for example, by combining it with other Information, or by including it in your own product or application.

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-53554966 .

andrew@vizzuality.com http://www.vizzuality.com

iriberri commented 10 years ago

Ok!

iriberri commented 10 years ago

I've downloaded the files and they don't seem to contain spatial data at all.

ONS Geography's postcode products allow users to relate an event's postcode to administrative, electoral and a wide range of other geographic areas.

National Statistics Postcode Products contain both live and terminated postcodes which means that they grow with each new version and currently contain over 2.5 million postcodes for the UK.

The table I got is this one: https://geocoding.cartodb.com/tables/onspd_may_2013_uk_o_1/

But I didn't find anything related with coordinates/polygons/geometries in the site. I'll check again.

andrewxhill commented 10 years ago

bummer... okay, so let's scratch GBR from the polygon list. Unless you want to google around a bit and see if the data exists somewhere out there with the correct license

On Thu, Aug 28, 2014 at 6:24 AM, Carla notifications@github.com wrote:

I've downloaded the files and they don't seem to contain spatial data at all.

_ONS Geography's postcode products allow users to relate an event's postcode to administrative, electoral and a wide range of other geographic areas.

National Statistics Postcode Products contain both live and terminated postcodes which means that they grow with each new version and currently contain over 2.5 million postcodes for the UK._

The table I got is this one: https://geocoding.cartodb.com/tables/onspd_may_2013_uk_o_1/

But I didn't find anything related with coordinates/polygons/geometries in the site. I'll check again.

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-53702200 .

andrew@vizzuality.com http://www.vizzuality.com

iriberri commented 10 years ago

I've been trying to google it, but for the moment i've only found a huge dataset of points valued in $99... but we already have points :-)

I'd say let's remove GBR in the meantime (to avoid future errors) but I'm going to continue looking for the polygons.

andrewxhill commented 10 years ago

cool!

On Thu, Aug 28, 2014 at 12:15 PM, Carla notifications@github.com wrote:

I've been trying to google it, but for the moment i've only found a huge dataset of points valued in $99... but we already have points :-)

I'd say let's remove GBR in the meantime (to avoid future errors) but I'm going to continue looking for the polygons.

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-53746969 .

andrew@vizzuality.com http://www.vizzuality.com

iriberri commented 10 years ago

Some links I considered interesting:

http://www.sharegeo.ac.uk/handle/10672/51?show=full (last update 2011)

http://gis.stackexchange.com/questions/32321/postcode-shape-files-for-the-uk

http://www.earthware.co.uk/blog/full-uk-postcodes-polygons-mostly-open-data/#.VABQFIC1Y0g

iriberri commented 10 years ago

@andrewxhill probably the most interesting thing I've found is this: http://www.ordnancesurvey.co.uk/business-and-government/licensing/using-creating-data-with-os-products/os-opendata.html

I think that downloads are free, and they make money by selling datasets in DVDs. Nevertheless, the downloads are not direct and you need to fill a request so after some time you get the download link at your email.

In theory, that site contains the data with which this was built: http://random.dev.openstreetmap.org/postcodes/

Details here: http://www.ordnancesurvey.co.uk/business-and-government/products/code-point-open.html

andrewxhill commented 10 years ago

Yep, if it is part of that OS opendata license, let's get it!

On Mon, Sep 1, 2014 at 9:08 AM, Carla notifications@github.com wrote:

@andrewxhill https://github.com/andrewxhill probably the most interesting thing I've found is this:

http://www.ordnancesurvey.co.uk/business-and-government/licensing/using-creating-data-with-os-products/os-opendata.html

I think that downloads are free, and they make money by selling datasets in DVDs. Nevertheless, the downloads are not direct and you need to fill a request so after some time you get the download link at your email.

In theory, that site contains the data with which this was built: http://random.dev.openstreetmap.org/postcodes/

Details here: http://www.ordnancesurvey.co.uk/business-and-government/products/code-point-open.html

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-54057047 .

andrew@vizzuality.com http://www.vizzuality.com

iriberri commented 10 years ago

This is a mess. I selected the options in which we are interested and I got this:

How to: Using our data in a product or service To resell our distribute our data, you would need to become a Licensed Partner. We work with some 300 companies, from start-ups to large multi-nationals, all of which add value to our data in a variety of different ways.

Learn more about the benefits of partnering with us

andrewxhill commented 10 years ago

haha

On Mon, Sep 1, 2014 at 12:06 PM, Carla notifications@github.com wrote:

This is a mess. I selected the options in which we are interested and I got this:

How to: Using our data in a product or service To resell our distribute our data, you would need to become a Licensed Partner. We work with some 300 companies, from start-ups to large multi-nationals, all of which add value to our data in a variety of different ways.

Learn more about the benefits of partnering with us

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-54075312 .

andrew@vizzuality.com http://www.vizzuality.com

andrewxhill commented 10 years ago

leave it for now... we'll come back to it after the rest

On Mon, Sep 1, 2014 at 12:35 PM, Andrew Hill andrewxhill@gmail.com wrote:

haha

On Mon, Sep 1, 2014 at 12:06 PM, Carla notifications@github.com wrote:

This is a mess. I selected the options in which we are interested and I got this:

How to: Using our data in a product or service To resell our distribute our data, you would need to become a Licensed Partner. We work with some 300 companies, from start-ups to large multi-nationals, all of which add value to our data in a variety of different ways.

Learn more about the benefits of partnering with us

— Reply to this email directly or view it on GitHub https://github.com/CartoDB/data-services/issues/51#issuecomment-54075312 .

andrew@vizzuality.com http://www.vizzuality.com

andrew@vizzuality.com http://www.vizzuality.com