Ploticus > Scripts >
proc breakaxis

proc breakaxis may be used to render a "break" symbol when preparing plots that have a broken axis in order to accomodate an extreme value.

In terms of plotting mechanics, breaking an axis means that one region of the plotting area uses one scale space, while the other region uses a different scale space. A "break" symbol is used to illustrate where these two regions meet. Ploticus cannot render broken axis plots automatically; generally they are "by hand" efforts.

The general approach is to use a "trick": set up one space, plot the values with a truncate option so that the extreme values do not go out of range, then set up a second space immediately adjacent to the first one, plot the values again so that only extremeties show, then use proc breakaxis to render a break symbol along the axis and again within the plot. The two plotting areas must be proportional in scaling.

Broken axis plotting works with proc bars, proc rangebar, and proc scatterplot. It currently does not work with lineplots or rangesweep, because these are unable to confine to the plotting area.


Gallery examples where this is used is brokenaxis and spence_rt


The breakpoint attribute must be specified.

axis     x | y

    The axis that is to be broken. Default is y.

breakpoint     plotvalue

    Where the break is to be rendered, in axis space. This attribute must be specified. Example:
      axis: y
      breakpoint: 25
    would break the Y axis at Y = 25.

location     axis | plotvalue

    The location where the break symbol is to be rendered. axis causes the symbol to be placed on the left or bottom axis. Otherwise, plotvalue is used. Default is axis. Example:
      axis: y
      breakpoint: 25
      location: axis
    The above code would render a break symbol on the Y axis at Y = 25.
    Another Example:
      axis: y
      breakpoint: 25
      location: 30
    The above code would render a break symbol at X = 30, Y = 25, presumably to break a bar, etc.

style     slant | straight

    The style of the break symbol. Default is slant.

linelength     n

    The length of the break symbol lines. n is in absolute units. Default is 0.2 inches.

fillcolor     color

    The color used for the rubout area. Default is the current background color. If you used a different color for the plotting area, that color should be specified here.

gapsize     n

    The distance (in absolute units) between the two lines of the break symbol.

linedetails     linedetails

    Controls the color, line width, etc. of the break symbol lines.


Ploticus 2.42 ... May 2013 Terms of use /