7

For a map of Wikipedia language prefixes, I need to color a map by a country's value in the 'language' column. I. e. all countries with the same language worldwide should share a color, which they should share with no group that is directly adjacent to them on land.

For a visual explanation of what I want to do, here's a map where I tried the same in GIMP (missing kk.wikipedia.org; warning, 5 MByte): enter image description here

I would now like to do the same in QGIS for easier handling, plus fully coloring a country in a raster map seems to be impossible (especially for islands).

Unfortunately, QGIS does not even seem to include a plugin to color adjacent polygons differently any more, not to mention such complex shapes. I found the plugin topoColour from QGIS 1.0, which seems to be exactly what I want, but it is of course extremely outdated.

Is there any kind of work flow to achieve the same half-manually? Manually applying the four-color theorem (or six- or eight-color in this case) is quite a daunting task, especially as QGIS doesn't seem to be meant for that. Note that I do want to keep countries separate so I can easily change their data when their language changes or a new Wikipedia is created.

I would not mind an outside tool like the standalone version of topoColour, but that one only colors by adjacency, not shared values like the plugin did. I only have Linux available, though. (Debian unstable.)

  • 2
    Is it even possible: "all countries with the same language worldwide should share a color, which they should share with none that is directly adjacent to them on land"? Following your logic USA and Canada should have the same colour but at the same time they need to have different colours which is mutually exclusive. Did I miss something? – SS_Rebelious Oct 20 '14 at 14:35
  • Could you insert a lower-resolution screenshot of your first attempt directly in your post? I can't access the URL you included. I think that might help @SS_Rebelious and others visualize your goal. – Erica Oct 20 '14 at 14:50
  • 1
    @Erica, I added the image to the question. I saw it before I asked for clarification. – SS_Rebelious Oct 20 '14 at 14:58
  • @SS_Rebellious, sorry, I mean no group that is adjacent to them. I. e. US and Canada are in the 'en' group and should be distinct from the countries in the 'es' group to the south. Edited the question. And thanks for adding the image! – Pikaro Oct 20 '14 at 15:19
  • 1
    @Pikaro, isn't categorized style by languge field is enough? You will have the same languages have the same colour and all colours will be unique to the given language. No need for extra plugin or something. – SS_Rebelious Oct 21 '14 at 17:22
1

At least, somebody took up the issue, and developed a new Map Coloring plugin. You need to enable experimental plugins in the Plugin manager to get it.

The output looks like this, after switching to Categorized styling on the COLORID field:

enter image description here

0

In the answers to this question, radouxju did post some code which could probably be used if you want to diy it: How to apply the four colors theorem in a polygon map in ArcGIS/ArcToolBox automatcally?

Or someone could be a hero and take up the offer to update TopoColour :) http://lists.osgeo.org/pipermail/qgis-developer/2013-April/025382.html

  • I fail to see how this suppose to help... – SS_Rebelious Oct 20 '14 at 14:32
  • @neuhausr, writing such a plugin myself would be hard - I'm only just learning how GIS works at all, so this would be quite a leap. So I'm hoping for an easier way. But thanks for the links! – Pikaro Oct 20 '14 at 15:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.