epiforecasts / covidregionaldata

An interface to subnational and national level COVID-19 data. For all countries supported, this includes a daily time-series of cases. Wherever available we also provide data on deaths, hospitalisations, and tests. National level data is also supported using a range of data sources as well as linelist data and links to intervention data sets.
https://epiforecasts.io/covidregionaldata/
Other
37 stars 18 forks source link

made draft hexsticker #383

Closed joseph-palmer closed 3 years ago

joseph-palmer commented 3 years ago

Had a go at making a hexsticker for the package. Probably could be better but thought I'd push something to get the ball rolling. All coments and critiques welcome as well as ideas!

(Also accidently pushed this to master before but undid this using git revert, appologies if this caused any issues)

closes #274

seabbs commented 3 years ago

I like it! No real comments from me except it looks like the height/width ratio might be a bit out? What do you think @RichardMN and @kathsherratt ?

RichardMN commented 3 years ago

I like the concept and think it shows what the package does.

I’d shrink the map a bit and at least on the version I’m looking at it doesn’t appear to be centre aligned left to right in the hex - this could be that eastern Russia is less visibly chunky than Alaska.

On a “nice to have” set of suggestions:

Some of these changes could then be applied back to the region map.

As a Canadian, I have some trouble with the projection used but I’m on holiday at the beach and don’t have the tools available to try meddling myself so revert to my not infrequent practice of suggestions which I hope @joseph-palmer might implement.

joseph-palmer commented 3 years ago

@RichardMN I will give it a go, I'm not to good with map stuff but I like the ideas. I don't know how to do the boarders thing but I can have a play around, might be able to do this with adding multiple layers. I can try and get a more comprehensive shapefile which has regions, then I can make something like a heat map with the different shades of blue for more intense data. I'm not sure if this will look too cluttered in such a small space though but I agree something like that would emphasise the regional aspect of the package. I will have a think about how to impliment that...

I've added two more versions and put these at the top of the README so people can compare each one. I have left the original (design 1) as is for reference. Design 2 I've projected onto a globe to see how that looks, the grid lines give it a bit of a Pan-Am vibe. Design 3 is like design one but more in proportion and cleaner. My preference is design 3. Please let me know which one you all prefer.

I had a play around with the font, happy to change this back if people are not a fan!

RichardMN commented 3 years ago

The font is fun!

I prefer option 2. Options 1 and 3 are still showing a strange offset of the map to the left.

Why isn’t South Africa coloured in?

I’ve an idea how to do greyed borders and will sketch it in a comment but beware that I’m not somewhere I can try this myself.

seabbs commented 3 years ago

I am terrible at making maps and/or projections so have little to offer here.

That being said I like 3 and 2 in that order I think as the project in 2 feels quite extreme to me but happy to go with it if it is more "correct" (or to try and get a balance between the two). Like the font. Like the idea of heat shading the data but really not clear what the correct dimension is to do it on.

It looks like South Africa is also missing from the vignette map so I expect a joining issue?

joseph-palmer commented 3 years ago

@RichardMN nice idea! The reason they are slightly off centre is so they fill the space best. Having them centred puts more blank space on the left and smushes New Zealand to the edge. Can also try a smaller size but then it looks a little barren and becomes harder to make out. I will make a 4th the same as 3 but centred to show what I mean.

I will fix South africa and add the boarders in for all of the designs.

joseph-palmer commented 3 years ago

I have removed the first design as it seems the debate is between the current design 1 and 2 (in README). Design 3 is the same as design 2 but with the map centered. I personally feel design 2 is better as it fills the space more, despite being slightly offset. Design 1 is growing on me quite a bit.

On colouring the regions and subregions with a gradient of blues and reds. I like this idea, but it is potentially quite a big job. We need a subregional shape file for each country and then colour this differently based on the amount of data, so I could try and get hold of these, put them into one big dataset and then have the colour gradient related to the total number of cases in that region/subregion. At the moment if a new country is added then just running the code for the hexsticker would make this again, but a new shapefile would be needed for any new countries added to keep it up to date, so this requires more ongoing work.

I think this will look cool and show off the regional aspect of the data, but its a fair bit more work and I'm not sure if the differences would be visable on the hexsticker in its normal size? Do you guys think this is worth the time on this?

kathsherratt commented 3 years ago

Hello, firstly, fab work Joe! I'm very neutral between designs as they all look great. If forced to vote I'd probably go with option 2 by a wafer thin margin.

Just chipping in about subnational region shading. I love the idea as it's the whole point of the package, but also think it needs a strong use case as I second Joe's comment that subregional shading will likely be quite troublesome to maintain.

We could use the rnaturalearth package to get subnational mapping fairly easily for the countries which have standard ISO geocodes. But as we know from painful experience, the standard geocodes are not always so easy to come by, and then matching them to the (sometimes out of date) rnaturalearth package can be surprisingly time-consuming.

seabbs commented 3 years ago

Agree think my vote is 2 and no colouring for now. In all the examples I see some odd effects with country borders on coast lines (they look like they are drawn twice?).

joseph-palmer commented 3 years ago

Cool, I will hold off on the colour map regions for now, although we can surly update the hexsticker at a later date if anyone comes up with an easy way to update it.

I think the coast lines are what all the borders should look like but when they border a country which we don't have data for the non-data countries border (which is lighter) takes precidence. I will get this fixed.

I've stayed inpartial in the vote but looks like design 2 wins with 2 votes to 1 (sorry @RichardMN!).

I will remove the other designs and put design 2 in the proper place and dimensions so its all ready to be merged in.

Thanks for all the feedback, looking sharp!

RichardMN commented 3 years ago

As @kathsherratt suggested I worked from natural earth data and also used rmapshaper to simplify the graphs (which just makes rendering a bit faster, at least for me).

https://github.com/RichardMN/covidregionaldata/tree/hexisticker-regions

Logo 5 (there was a logo 4 and I didn't want to mash it) is a proof of concept of using the natural earth data and of displaying different regions. There is no attempt to apply our data (the extra credit bit) and currently I am mashing a region code to get something to apply a divergent palette to, while trying to put values for countries where we have level 2 data in 0-6 and the rest in 7-13; this sort of works though there are some stray light blues/pinks where they shouldn't be and my if_else statement isn't capturing the U.S. correctly. This could also be shifted to a different projection but my focus has been to get regions showing. I am not trying to show level 2 regions because they're tiny

logo 5

seabbs commented 3 years ago

Ah I think that looks really cool @RichardMN and does really nicely convey what is in the package (even without linking the shading to anything - this is a logo after all!).

seabbs commented 3 years ago

@joseph-palmer ping 😄

joseph-palmer commented 3 years ago

Apologies for the delay, I'm working a on a seperate thing with my PhD at the moment but I will try and get this sorted ASAP