LINE Subcommand (IGRAPH command)
LINE
creates
line charts, dot charts, and ribbon charts. These charts summarize
categories of one or more variables. Line charts tend to emphasize
flow or movement instead of individual values. They are commonly used
to display data over time and therefore can be used to give a good
sense of trends. A ribbon chart is similar to a line chart, with the
lines displayed as ribbons in a third dimension. Ribbon charts can
either have two dimensions displayed with a 3-D effect, or they can
have three dimensions.
The following keywords are available:
summary function. Defines a
function used to summarize the variable defined on the Y subcommand. If the Y axis assignment is
$COUNT
or $PCT
, the LINE
subcommand
cannot have a summary function. If the Y
subcommand specifies TYPE=CATEGORICAL
, then LINE
can specify only
MODE
as the summary function.
STYLE. Chart can
include dots and lines ( DOTLINE
), lines only ( LINE
), or dots
only ( DOT
). The keyword NONE
creates an empty chart.
DROPLINE. Indicates
whether drop lines through points having the same value of a variable
are included in the chart ( ON
) or not ( OFF
). To include drop lines, specify a categorical variable on the STYLE
, COLOR
, or SIZE
subcommands.
LABEL. Labels points
with the actual values corresponding to the dependent axis ( VAL
), the percentage of cases ( PCT
), and the number of cases
included in each data point ( N
). The default
is no labels.
LINELABEL. Labels lines
with category labels ( CAT
), the percentage of cases ( PCT
), and the number of cases included in each line ( N
). The default is no labels.
BREAK. Indicates
whether the lines break at missing values ( MISSING
) or not
( NONE
).
The INTERPOLATE
keyword determines how the lines connecting the points are drawn.
Options include:
STRAIGHT. Straight lines.
LSTEP. A horizontal line extends from each data point. A vertical riser connects the line to the next data point.
CSTEP. Each data point is centered on a horizontal line that extends half of the distance between consecutive points. Vertical risers connect the line to the next horizontal line.
RSTEP. A horizontal line terminates at each data point. A vertical riser extends from each data point, connecting to the next horizontal line.
LJUMP. A horizontal line extends from each data point. No vertical risers connect the lines to the points.
RJUMP. A horizontal line terminates at each data point. No vertical risers connect the points to the next horizontal line.
CJUMP. A horizontal line is centered at each data point, extending half of the distance between consecutive points. No vertical risers connect the lines.
SPLINE. Connects data points with a cubic spline.
LAGRANGE3. This is no longer supported and is now
an alias for SPLINE
.
LAGRANGE5. This is no longer supported and is
now an alias for SPLINE
.
Example
IGRAPH
/X1=VAR(volume95) TYPE=CATEGORICAL
/Y=VAR(sales96) TYPE=SCALE
/COLOR=VAR(volume94) TYPE=CATEGORICAL
/COORDINATE=VERTICAL
/LINE (MEAN) STYLE=LINE DROPLINE=ON LABEL VAL
INTERPOLATE=STRAIGHT BREAK=MISSING.
-
LINE
creates a line chart. The lines represent the mean value of sales96 for each category of volume95. - The chart contains a line for each category of volume94, with droplines connecting the lines at each category of volume95.
-
LABEL
labels the lines with the mean sales96 value for each category of volume95. -
INTERPOLATE
specifies that straight lines connect the mean sales96 values across the volume95 categories. -
BREAK
indicates that the lines will break at any missing values.