cleanplots is a Stata graphics scheme to change the default look of Stata graphics. It is designed to implement data visualization best practices by default—limiting the amount of time you have to spend tweaking the graph to be maximally readable and usable. In addition, the color palette is chosen to be colorblind friendly and to automate printing in black and white, so that a single figure will work in color or printed in black and white.
The sections below detail (1) installation instructions, (2) the help file, (3) features of the graphics scheme, (4) examples that compare cleanplots to Stata's default graphics scheme, and (5) a note on updates to the scheme and prior versions.
To install in Stata:
net install cleanplots, from("https://tdmize.github.io/data") replace
Once installed, to change your graphics scheme:
set scheme cleanplots, perm
Read the cleanplots help file by executing the following command (also available here):
help cleanplots
In general, I do not think the use of a graphics scheme requires citation. So for most cases, feel free to use cleanplots without citation. But, if you need/want a citation you can cite cleanplots as:
Mize, Trenton D. 2017. "cleanplots: Stata graphics scheme for easy and effective data visualizations." https://www.trentonmize.com/software/cleanplots
cleanplots implements a host of features that draw on best data visualization practices (some of which are borrowed from the excellent black and white graphics scheme plainplots from Bischof (2017)). This allows you to make publication quality Stata graphics with very little effort. With cleanplots, many of the defaults you would change before via code are already changed for you. For example:
Default colors are easier to distinguish from each other and are more aesthetically pleasing
Default colors are colorblind friendly
Default colors allow you to make one graph which is effective in both color and when printed in black and white
Marker shapes and line features (e.g. solid, dashed, etc.) better distinguish lines and ensure lines will be distinguishable if printing in black and white
All axis markers are horizontal – thus easier to read
A non-invasive light grid is placed on all plots
Both vertical and horizontal gridlines
The background of the plot is white
Legends are placed to right of the graph
Text colors on the graph are consistent
And many more!
One benefit of the cleanplots scheme is that you only need to create one set of figures because the colors and markers/symbols/lines cleanplots uses can be printed in black and white/grayscale and still be easily distinguished. The figures below illustrate the color and grayscale version of the same figures:
About 5% of the population has some form of colorblindness (red/green being the most common which is why you should always avoid having red and green together on your figure). This excellent website Coloring for Colorblindness lets you check your color schemes to see how they will be viewed for those who are colorblind.
The figure below shows how the first six default cleanplots colors ("true") look to individuals with various types of colorblindness. As the figure illustrates, the colors have been chosen because they are easily distinguishable across all types of colorblindness. Color cannot be reliably used to distinguish more than six colors for the whole population; if you have more aspects of the graph, always include additional varying markers, line patterns, or other differentiators. cleanplots automates this.
The cleanplots scheme includes 10 total colors, shown below with their RGB and Hex codes. The scheme is a nominal theme with no implied ordering from the colors.
For bar charts and area plots, which include lots of data ink, cleanplots uses a less saturated palette of softer olors.
This section illustrates default choices of some common plots using cleanplots (on the left) vs Stata's default graphics scheme (s2color; on the right). Note I recommend more polished figures for use in papers; these are only meant to illustrate the difference in the default choices.
hist vidtv, percent
marginsplot, recastci(rline) ciopts(lpat(dash))
twoway scatter residstd index [w=influence]
marginsplot, recast(scatter) x(educ)
cibar income, over1(occcat)
lowess job phd
cleanplots was given an update in July 2026. Of most focus is the color choices for colors 6 - 10, which are now more colorblind friendly and more easily distinguishable. In addition, the intensity of colors now alternate for each odd and even aspect of the graph, aiding in black and white printing. Some further minor tweaks to marker shapes were also incorporated. Finally, the legend is now due right of the graph, instead of in the bottom right.
To obtain the newest version:
net install cleanplots, from("https://tdmize.github.io/data") replace
I recommend using the most up to date version. But, if you are feeling nostalgic and want the original scheme, it is preserved as cleanplots_classic:
set scheme cleanplots_classic