Hello Stata-Experts,
I generated a wonderful heat map with the spmap package. Now I am wondering if there's any possibility to reverse the color coding. I want higher values to be shown in lighter colors and the other way around.
The code of the map looks like:
colorpalette plasma, n(18) nograph reverse
local colors `r(p)'
spmap age_mean using nuts3_shp, ///
id(_ID) cln(10) fcolor("`colors'") ///
ocolor(gs6 ..) osize(0.03 ..) ///
ndfcolor(gs14) ndocolor(gs6 ..) ndsize(0.03 ..) ndlabel("No Data") ///
polygon(data("nuts1_shp") ocolor(black) osize(0.08) legenda(on) legl("NUTS3")) ///
legend(pos(11) size(1.5) symx(2.5) symy(1.5)) legtitle("Age") legstyle(2) ///
title("{fontface Arial Bold:Dependency Ratio in Europe by NUTS 3 regions}", size(medsmall)) ///
note("Data source: Eurostat table: demo_r_pjanind3. NUTS 2016 layers from Eurostat GISCO.", size(1.5))
I already tried the -colrspace- package, but I keep getting white maps as result. Here is the code:
ssc install colrspace, replace
colorpalette plasma, select( 1 2 3 4 5 6 7 8 10 12 14 16 18 20) nograph reverse
I appreciate any kind of help!
Thank you!
Related Posts with Reverse the color of spmap
Recursive modelsHello! I am running a recursive model with three equations. the first dependent variable in the firs…
Saving the output of -which-I have written an ado command that calls a native executable (an exe file in Windows). Users have tr…
How to modify the width of x- and y-axis are the same?Hi everyone, In my example, delta1 = 0.05 (y-axis) has the width is larger than delta 2 = 0.2 (x-ax…
"too few variables" foreachHi, I'd like to recode (reverse) a list of 24 dichotomous variables (0/1). The following should ill…
How to interpret variance on different levels in melogitDear all, I am analysing what are the determinants for the adoption of bonus compensation for a firm…
Subscribe to:
Post Comments (Atom)
0 Response to Reverse the color of spmap
Post a Comment