highcharts / map-collection-dist

Other
30 stars 37 forks source link

Map of Norway: wrong data on municipality level, wrong boundary, wrong codes. #91

Closed HuidongTian closed 2 years ago

HuidongTian commented 2 years ago

The Geojson maps for Norway have several problems:

  1. The map at the county level does not match the boundary of the map at the municipality level
  2. There are several places that are wrong on the municipality level map. e.g. Orkland, Malvik.
  3. The code for the municipality level map are mismatched.

    https://code.highcharts.com/mapdata/countries/no/no-all-all.geo.json

e.g. "hc-group":"admin2","hc-key":"no-tf-3020","hc-a2":"NO","name":"Nordkapp"} "hc-group":"admin2","hc-key":"no-vi-5435","hc-a2":"NF","name":"Norde Follo"

3020 is for Norde Follo, and 5435 is for Nordkapp.

KacperMadej commented 2 years ago

Hi @HuidongTian

Thank you for reporting the problems.

If you could share some details, provide more info, and the source you have used for the reference then it would be greatly appreciated.

  1. Could you share the links for the problematic maps and the correct source for reference?
  2. Could you specify what is wrong with them so don't miss anything? Are there any other places than the mentioned two that are wrong?
  3. Could you share the source of the correct codes for reference? Are there any other problems like that you have noticed?
HuidongTian commented 2 years ago

Hi, @KacperMadej,

  1. I have included the link, I can include it again: https://code.highcharts.com/mapdata/countries/no/no-all-all.geo.json
  2. If you check the municipalities: e.g. Orkland, Malvik, you will find that their boundaries are wrong, not due to the resolution.
  3. You can take this as the correct source of codes. https://www.kartverket.no/til-lands/fakta-om-norge/norske-fylke-og-kommunar. I didn't check other problems, we are going to publish some cancer-related maps, my leader realized some areas are wired, so I check my codes, and found the problem is from the map I downloaded.

Besides, there is another problem is: the boundary of county-level map can not match with the boundary of municipality-level map.

https://code.highcharts.com/mapdata/countries/no/no-all.geo.json https://code.highcharts.com/mapdata/countries/no/no-all-all.geo.json

If the maps were generated in the same way, you may also need to check other countries' maps.

KacperMadej commented 2 years ago

Thank you for the details.

Internal note: Comparison map with visible differences: https://jsfiddle.net/BlackLabel/mh6afb82/1/

HuidongTian commented 2 years ago

Hi @KacperMadej do you have a time table to fix this issue?

KacperMadej commented 2 years ago

It's scheduled for the next 2 weeks so if everything goes well there should be a usable solution by that time. https://github.com/highcharts/highcharts/projects/32#card-73059082

KacperMadej commented 2 years ago

If you check the municipalities: e.g. Orkland, Malvik, you will find that their boundaries are wrong, not due to the resolution.

@HuidongTian - I don't see what is wrong here - the boundaries seem ok to me. Below is a comparison between norgeskart, Highcharts Maps map (and this is the same on the Trøndelag map) and Wikipedia.

nor91

HuidongTian commented 2 years ago

@KacperMadej

  1. NorgeKart cannot be wrong. The map shown above is the boundary map including their ocean region, while the map from WiKipedia shows only their land boundary, but still, you can see the boundary of their ocean/sea area.
  2. It's difficult to see the error if you focus only on one municipality. Check the gap between Orkland and Rindal, there is a gap.
  3. Zoom in the "Malvik" as much as possible, you will see two parts are in another municipality.
KacperMadej commented 2 years ago

A lot is happening here, so let's go with a list and separate small issues for faster resolving of those:

HuidongTian commented 2 years ago

@KacperMadej

  1. 5435 & 3020 is just an example of the mis-matching of municipality code and name. There could be more mismatched codes and names. You should go through all of them.
  2. Norgekart cannot be wrong. But the way of using their maps could be. For generating geojson format map, it's better don't choose such high resolution map because that will introduce redundant data, then make the size of the generated geojson file unnecessarily high. You can easily find the generated json file has a lot of repeated points. For example, this one is much better. Screenshot_20211125-174314 Which will generate the simplified map like this one. 1920px-NO_5031_Malvik svg
raf18seb commented 2 years ago

Done in https://github.com/highcharts/map-collection/pull/14

KacperMadej commented 2 years ago

@HuidongTian

  1. Will be taken care of in https://github.com/highcharts/map-collection-dist/issues/95
  2. Simplification of geometry is done automatically in our map processing scripts so this could depend on the source - using a simplified source will prevent differences between the source and our maps. In the below demo a different map source is used. That demo could be used as a reference and as a workaround: https://jsfiddle.net/BlackLabel/fmunxt2e/1/