*! version 1.1 30Aug2018

*! Help file by Mead Over for style files by by Mallika Snyder, Center for Global Development August, 2018

Title

CGD_Colors: A package to install CGD colors for use in Stata graphs.

Description

This package installs CGD colors for subsequent use in Stata graphs and schemes.
[G-4] colorstyle.

Remarks

As documented in colorstyle, Stata users who want to customize
the colors used in their graphs, but prefer to avoid the tedium of looking up
and specifying RGB codes, have the option of specifying pre-defined,
named colors. The user can list the pre-defined colors available on
his or her installation of Stata by typing: graph query colorstyle
from inside Stata.

In 2018, as part of its periodic revision of its web site and its publication
styles, the Center for Global Development
specified a color palette as the default palette for CGD web content and
publications. This Stata package adds these colors to those available by
name to the Stata user.

The CGD colors added to Stata with this package are:

Primary
cgdteal Teal

cgddkgray Dark gray

cgdwmgray Warm gray

Secondary
cgdred Red

cgdorange Orange

cgdyellow Yellow

cgdgreen Green

cgdblue Blue

cgdpurple Purple

cgdbeige Beige

cgdbluegray Blue gray

cgdltgray Light gray

To learn more about any specific color, use Stata's palette color commmand.
For example, by typing palette color teal at the Stata prompt, you will see
that Stata's version of that color is defined by the RGB codes "110 142 132".

Once you have installed this package, you can use this commmand to compare any
two colors, such as Stata's teal color and CGD's version of teal, by typing:
palette color teal cgdteal. You will see that CGD's teal is defined
by the RGD code "0 103 127".

Examples

*	Clear your current data from memory and load Stata's demo data
sysuse auto, clear

*	First construct a bar graph using the colors in your current default Stata graphics scheme
graph bar length displacement turn mpg gear_ratio trunk

*	Now construct a bar graph using CGD Teal as the color of the first bar
graph bar length displacement turn mpg gear_ratio trunk, bar(1, fcolor(cgdteal) lcolor(cgdteal))

*	Or use CGD Teal as the color of the fourth bar
graph bar length displacement turn mpg gear_ratio trunk, bar(4, fcolor(cgdteal) lcolor(cgdteal))

*	The following syntax will assign the first six of CGD's colors to the six bars
*	But this code must be executed from DO file.
graph bar length displacement turn mpg gear_ratio trunk, ///
bar(1, fcolor(cgdteal) lcolor(cgdteal)) ///
bar(2, fcolor(cgddkgray) lcolor(cgddkgray)) ///
bar(3, fcolor(cgdwmgray) lcolor(cgdwmgray)) ///
bar(4, fcolor(cgdred) lcolor(cgdred)) ///
bar(5, fcolor(cgdorange) lcolor(cgdorange)) ///
bar(6, fcolor(cgdyellow) lcolor(cgdyellow))

*	Bundled with this package is a DO file called cgd_colors_examples.do
*	To execute all of the above commmands, including the bar graph using a CGD
*	color for all 6 of the bars, run this DO file from your Stata commmand line.

Author

Mallika Snyder coded the "style" files which define CGD's colors based on their RGB definitions.

Contact
Mallika Snyder at:
MSnyder@CGDev.Org or
Mead Over at:
MOver@CGDev.Org with questions, problems or suggestions.