Home  /  Resources & support  /  FAQs  /  Number of items in the legend
Note: This FAQ is relevant for users of releases prior to Stata 8.

## How many items can be identified in the legend?

 Title Number of items in the legend Author Jeremy Wernow, StataCorp

Stata will only allow four variable names in the legend. This feature is hard-coded into Stata and cannot presently be changed. An alternative is to use a graphics package to edit the graph and insert more symbols and text into the legend. See the FAQ “How can I edit a Stata graph in MS Word” for instructions.

There is also a community-contributed program by Nicholas Cox, Durham University, UK, called keyplot, that allows more than four items on the legend. You can download this program using the net search command:

. net search keyplot (contacting http://www.stata.com) 3 packages found (STB listed first) ----------------------------------- keyplot from http://fmwww.bc.edu/RePEc/bocode/k 'KEYPLOT': module to generate scatter plot with keys in user-chosen positions / keyplot produces a standard scatter plot with between one and ten / y variables and one x variable, except that it attempts a more / flexible approach to placing symbol keys for the y variables, / either in ordplot from http://fmwww.bc.edu/RePEc/bocode/o 'ORDPLOT': module for cumulative distribution plot of ordinal variable / ordplot produces a cumulative distribution plot for an ordinal / numeric variable ordvar. The cumulative probability is plotted on / the y axis and ordvar is plotted on the x axis. ordplot is / designed primarily for data pwploti from http://fmwww.bc.edu/RePEc/bocode/p 'PWPLOTI': module to plot power curve for sample size and power calculation / pwploti plots statistical power on the Y-axis and the required / sample size of on the X-axis. Several lines can be plotted on / the power curve, each one corresponding to a value of difference / .