TPVAR: Stata module to generate turning-point variable for graphics labelling
Nicholas J. Cox
tpvar generates a variable for use in labelling data points on a scatter plot with appropriate text that appears near point symbols. Given the current sort order, tpvar identifies observations in which the value of varname is either above both previous and following values or below both previous and following values. These are local maxima and minima, or turning points. A new variable newvar is generated for these turning points, which takes values of varname + above * range of varname and varname - below * range of varname for maxima and minima respectively. These values of newvar will often be good places to put text, just above and just below point symbols for varname.
In order to set up a list of libraries that you have access to,
you must first login
or sign up.
Then set up a personal list of libraries from your profile page by
clicking on your user name at the top right of any screen.