📄 graph_matrix.hlp
字号:
{smcl}
{* 07mar2005}{...}
{cmd:help graph matrix} {right:dialogs: {bf:{dialog graph_matrix:graph matrix}} }
{right:{dialog ematrix:easy graph matrix}}
{hline}
{* index matrix graphs}{...}
{* index scatterplot matrices}{...}
{* index half tt option}{...}
{* index maxes() tt option}{...}
{* index jitter tt option}{...}
{* index jitterseed() tt option}{...}
{* index iscale() tt option}{...}
{title:Title}
{p2colset 5 25 27 2}{...}
{p2col :{hi:[G] graph matrix} {hline 2}}Matrix graphs{p_end}
{p2colreset}{...}
{title:Syntax}
{p 8 43 2}
{cmdab:gr:aph}
{cmd:matrix}
{it:varlist}
{ifin}
{weight}
[{cmd:,}
{it:options}]
{it:options}{col 40}description
{hline 70}
{cmd:half}{...}
{col 40}draw lower triangle only
{it:{help marker_options}}{...}
{col 40}look of markers
{it:{help marker_label_options}}{...}
{col 40}include labels on markers
{cmd:jitter(}{it:{help relativesize}}{cmd:)}{col 40}{...}
{col 40}perturb location of markers
{cmd:jitterseed(}{it:#}{cmd:)}{col 40}{...}
random number seed for {cmd:jitter()}
{cmdab:diag:onal:(}{it:stringlist}{cmd:,} ...{cmd:)}{...}
{col 40}override text on diagonal
{help scale_option:{bf:scale(}{it:#}{bf:)}}{...}
{col 40}overall size of symbols, labels, etc.
{cmd:iscale(}[{cmd:*}]{it:#}{cmd:)}{...}
{col 40}size of symbols, labels, within plots
{cmdab:max:es:(}{it:{help axis_scale_options}}
{it:{help axis_label_options}}{cmd:)}{...}
{col 40}labels, ticks, grids, log scales, etc.
{it:{help axis_label_options}}{...}
{col 40}axis-by-axis control
{help by_option:{bf:by(}{it:varlist}{bf:, ...)}}{...}
{col 40}repeat for subgroups
{it:{help std_options}}{...}
{col 40}titles, aspect ratio, saving to disk
{hline 70}
{pin}
Note that all options allowed by
{cmd:graph} {cmd:twoway} {cmd:scatter} are also allowed, but they
are ignored.
{cmd:half},
{cmd:diagonal()},
{cmd:scale()}, and
{cmd:iscale()} are {it:unique};
{cmd:jitter()} and
{cmd:jitterseed()}
are {it:rightmost} and
{cmd:maxes()} is {it:merged-implicit};
see {help repeated options}.
{pstd}
{it:stringlist}{cmd:,} ...,
the argument allowed by {cmd:diagonal()},
is defined
{pin}
[{c -(}{cmd:.}|{cmd:"}{it:string}{cmd:"}{c )-}]
[ {c -(}{cmd:.}|{cmd:"}{it:string}{cmd:"}{c )-} ... ]
[{cmd:,} {it:{help textbox_options}}]
{pstd}
{cmd:aweight}s,
{cmd:fweight}s, and
{cmd:pweight}s are allowed; see {help weight}.
Weights affect the size of the markers.
See {hi:Weighted markers} in {helpb scatter}.
{title:Description}
{pstd}
{cmd:graph} {cmd:matrix}
draws scatterplot matrices.
{title:Options}
{phang}
{cmd:half}
specifies that only the lower triangle of the scatterplot matrix be
drawn.
{phang}
{it:marker_options}
specify the look of the markers used to designate the location of the
points. The important {it:marker_options} are
{cmd:msymbol()}, {cmd:mcolor()}, and {cmd:msize()}.
{pmore}
The default symbol used is {cmd:msymbol(O)}{hline 2}solid circles. You
specify {cmd:msymbol(Oh)} if you want hollow circles (a recommended
alternative). If you have lots of observations, we recommend specifying
{cmd:msymbol(p)}; see
{help graph matrix##remarks2:Marker symbols and the number of observations}
under {hi:Remarks} below. See {it:{help symbolstyle}} for a list of
marker symbol choices.
{pmore}
The default {cmd:mcolor()} is dictated by the scheme; see
{help schemes}. See {it:{help colorstyle}} for a list of color
choices.
{pmore}
Be careful specifying the {cmd:msize()} option. In {cmd:graph}
{cmd:matrix}, the size of the markers varies with the number of variables
specified; see option {cmd:iscale()} below. If you specify {cmd:msize()},
that will override the automatic scaling.
{pmore}
See {it:{help marker_options}} for more information on markers.
{phang}
{it:marker_label_options}
allow placing identifying labels on the points. To obtain this, you
specify the {it:marker_label_option} {cmd:mlabel(}{it:varname}{cmd:)}; see
{it:{help marker_label_options}}. These options are of
little use in the case of scatterplot matrices because they make the graph
seem too crowded.
{phang}
{cmd:jitter(}{it:relativesize}{cmd:)}
adds spherical random noise to the data before plotting. This is useful
when plotting data that otherwise would result in points plotted on top
of each other. See {hi:Jittered markers} in {helpb scatter} for an
explanation of jittering.
{phang}
{cmd:jitterseed(}{it:#}{cmd:)}
specifies the seed for the random noise added by the {cmd:jitter()}
option. {it:#} should be specified as a positive integer. Use this
option to reproduce the same plotted points when the
{cmd:jitter()} option is specified.
{phang}
{cmd:diagonal(}[{it:stringlist}][{cmd:,} {it:textbox_options}]{cmd:)}
specifies text and its style to be displayed along the diagonal.
This text serves to label the graphs (axes).
By default, what appears along the diagonals are the variable labels
of the variables of {it:varlist} or, if a variable has no variable
label, its name. Typing
{phang3}
{cmd:. graph matrix mpg weight displ, diag(. "Weight of car")}
{pmore}
would change the text appearing in the cell corresponding to variable
{cmd:weight}. Note that we specified period ({cmd:.}) to leave the text
in the first cell unchanged, and we did not bother to type
a third string or a period; so we left the third element unchanged, too.
{pmore}
You may specify {it:textbox_options} following {it:stringlist} (which may
itself be omitted) and a comma. These options will modify the style in
which the text is presented but are of little use in this case. We
recommend that you do not specify {cmd:diagonal(,size())} to override the
default sizing of the text. By default, the size of text varies with the
number of variables specified; see option {cmd:iscale()} below.
Specifying {cmd:diagonal(,size())} will override the automatic size
scaling. See {it:{help textbox_options}} for more information on
textboxes.
{phang}
{cmd:scale(}{it:#}{cmd:)}
specifies a multiplier that affects the size of all text and
markers in a graph. {cmd:scale(1)} is the default, and {cmd:scale(1.2)}
would make all text and markers 20% larger.
See {it:{help scale_option}}.
{phang}
{cmd:iscale(}{it:#}{cmd:)}
and
{cmd:iscale(*}{it:#}{cmd:)}
specify an adjustment (multiplier) to be used to scale the markers,
the text appearing along the diagonals, and the labels and ticks appearing
on the axes.
{pmore}
By default, {cmd:iscale()} gets smaller and smaller the larger is
{it:n}, the number of variables specified in {it:varlist}.
The default is parameterized as a multiplier
f({it:n}){hline 2}0<f({it:n})<1, f'({it:n})<0{hline 2}that is used as a
multiplier for {cmd:msize()}, {cmd:diagonal(,size())},
{cmd:maxes(labsize())}, and {cmd:maxes(tlength())}.
{pmore}
If you specify {cmd:iscale(}{it:#}{cmd:)}, the number you specify is
substituted for f({it:n}). We recommend that you specify a number between
0 and 1, but you are free to specify numbers larger than 1.
{pmore}
If you specify {cmd:iscale(*}{it:#}{cmd:)}, the number you specify is
multiplied by f({it:n}), and that product is used to scale text.
In this case, you should specify {it:#}>0; {it:#}>1
merely means you want the text to be bigger than {cmd:graph}
{cmd:matrix} would otherwise choose.
{phang}
{cmd:maxes(}{it:axis_scale_options axis_label_options}{cmd:)}
affect the scaling and look of the axes. This is a case where you specify
options within options.
{pmore}
Consider the {it:axis_scale_options}
{c -(}{cmd:y}|{cmd:x}{c )-}{cmd:scale(log)}, which produces logarithmic scales.
Type {cmd:maxes(yscale(log)} {cmd:xscale(log))} to draw
the scatterplot matrix using log scales. Remember to specify both
{cmd:xscale(log)} and {cmd:yscale(log)}, unless you really
want just the {it:y} axis or just the {it:x} axis logged.
{pmore}
Or consider the {it:axis_label_options}
{c -(}{cmd:y}|{cmd:x}{c )-}{cmd:label(,grid)}, which adds grid lines.
Specify
{cmd:maxes(ylabel(,grid))} to add grid lines across,
{cmd:maxes(xlabel(,grid))} to add grid lines vertically,
and both options to add grid lines in both directions.
When using both, you can specify the {cmd:maxes()} option
twice{hline 2}{cmd:maxes(ylabel(,grid)) maxes(xlabel(,grid))}{hline 2}or
once combined{hline 2}{cmd:maxes(ylabel(,grid) xlabel(,grid))}{hline 2}it
makes no difference because {cmd:maxes()} is {it:merged-implicit}; see
{help repeated options}.
{pmore}
See {it:{help axis_scale_options}} and
{it:{help axis_label_options}} for the suboptions that may appear
inside {cmd:maxes()}. In reading those entries, ignore the
{cmd:axis(}{it:#}{cmd:)} suboption; {cmd:graph} {cmd:matrix} will ignore
it if you specify it.
{phang}
{it:axis_label_options}
allow you to assert axis-by-axis control over the labeling. Do not
confuse this with {cmd:maxes(}{it:axis_label_options}{cmd:)},
which specifies options that affect all the axes.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -