Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include different options for region color palette #51

Open
johannah-pik opened this issue Dec 13, 2022 · 9 comments
Open

Include different options for region color palette #51

johannah-pik opened this issue Dec 13, 2022 · 9 comments
Assignees

Comments

@johannah-pik
Copy link
Contributor

johannah-pik commented Dec 13, 2022

Depending on the use case, different color palettes are desired for the REMIND regions.
The new region colors from this PR are optimized for distinguishability (e.g. for the REMIND validation).
For publications, grouped colors for like-wise regions could be better.

Here is a proposal from Nico for a grouped color palette, that could be implemented as an alternative choice:

OECD regions
plotstyle.add("EUR", "EU", rgb(0.0, 0.0, 0.99, 1), marker = 23, replace = TRUE )
plotstyle.add("NEU", "Other Europe", rgb(0.0, 0.0, 0.65, 1), marker = 9, replace = TRUE )
plotstyle.add("USA", "USA", rgb(0.5, 0.5, 0.99, 1), marker = 10, replace = TRUE )
plotstyle.add("JPN", "Japan", rgb(0.0, 0.5, 0.99, 1), marker = 13, replace = TRUE )
plotstyle.add("CAZ", "Can, Aus, NZ", rgb(0.3, 0.3, 0.8, 1), marker = 17, replace = TRUE )

Regions with developing and Emerging markets
plotstyle.add("CHA", "China", rgb(0.3, 0.99, 0.3, 1), marker = 19, replace = TRUE )
plotstyle.add("IND", "India", rgb(0.3, 0.65, 0.3, 1), marker = 8, replace = TRUE )
plotstyle.add("OAS", "Other Asia", rgb(0.6, 0.99, 0.0, 1), marker = 11, replace = TRUE )
plotstyle.add("SSA", "Sub-Sahra Africa", rgb(0.5, 0.0, 0.99, 1), marker = 15, replace = TRUE )
plotstyle.add("MEA", "Middle East & N. Africa", rgb(0.7, 0.2, 0.99, 1), marker = 17, replace = TRUE )
plotstyle.add("LAM", "Latin America", rgb(0.9, 0.6, 0.5, 1), marker = 12, replace = TRUE

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member

0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q commented Dec 14, 2022

State as of 0.140.1:
image

This proposal:
image

@nicobauer
Copy link

Thanks! Maybe it is useful also to somehow group the markers. Proposal (with reference at the end):
OECD/high income regions: 15-19
China, India, OAS: 2,1,6
LAM, REF: 12, 13
MEA, SSA: 3,4
#51

@robertpietzcker
Copy link

This merge request:

sorry, maybe I am a bit slow - what do you mean with "this merge" - Nico's proposal?
The option to choose a different palette (such as Nico's proposal) still has to be implemented sometime in the future, right?

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member

Clarified. This is indeed a proposal, not a merge request.

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member

The option to choose a different palette (such as Nico's proposal) still has to be implemented sometime in the future, right?

Very much so, as plotstyle.add() is a destructive operation.

@nicobauer
Copy link

Somehow I remember that @dklein-pik was the master of plotstyle and the default csv file that is used. David, if so, could you up-date?

@nicobauer
Copy link

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q I only use plotstyle.add locally, where it does not affect the overall default values.

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q
Copy link
Member

@0UmfHxcvx5J7JoaOhFSs5mncnisTJJ6q I only use plotstyle.add locally, where it does not affect the overall default values.

Yes. But you can't go back to default values. So there is no option for you to use either one or the other, except for manually setting them every time. Which defeats the purpose of the plot styles to some degree.

@dklein-pik
Copy link
Member

Somehow I remember that @dklein-pik was the master of plotstyle and the default csv file that is used. David, if so, could you up-date?

I am not sure what you want. But if you want to update colors you can do it here https://github.com/pik-piam/mip/blob/master/inst/extdata/plotstyle.csv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants