Stata 15 help for gr7other

help gr7other (out-of-date command) -------------------------------------------------------------------------------

Warning

This help file documents the old version of Stata's graph command. See graph for the modern version.

Stata runs the old version of graph whenever graph is invoked under version control (see version) or when you use the graph7 or gr7 command.

graph7 command -- saving, printing, and multiple image options

{graph7 | gr7} [varlist] [weight] [if exp] [in range] [, graph_type specific_options common_options]

{graph7 | gr7} using filename [filename ...] [, graph_using_options]

by is allowed; see by.

The saving, printing, and multiple image common_options for graph7 are

saving(filename[,replace]) by(varname) total bsize(#) Rescale xsize(#) ysize(#)

The graph_using_options for graph7 using are

saving(filename[,replace]) margin(#) title("text") t1title("text") t2title("text") b1title("text") b2title("text") l1title("text") l2title("text") r1title("text") r2title("text")

Information on the graph7 command and the different graph_types is found in graph7. this entry details the saving, printing, and multiple image common_options and graph_using_options. Help for the other common_options is also available. See gr7axes for title and axes; gr7sym for symbols and lines; gr7color for color and shading.

Options

saving(filename[,replace]) saves the graph in a file that can be reviewed by graph7 using (see graph7) and printed with print. If you do not specify an extension, .gph will be assumed.

by(varname) is allowed with all styles except matrix and star. It requests that graphs be drawn separately for the groups defined by varname and combined in one image. "graph7 y x, by(region)" would draw one graph for each value of region and array them on the screen.

With bar (see gr7bar) and box (see gr7box), by() draws one axis and then groups the bars or boxes according to varname. "graph7 y x, by(region) box" would draw 8 boxes if region took on four different values.

total may be specified only with by(). It requests that an additional group be added reflecting all the data. If region takes on four values, "graph7 y x, by(region) total" would draw 5 graphs in one image, one for each region and one more for all four regions combined.

bsize(#) specifies the size of the text to be used to label the by-groups, with 100 (meaning 100% of normal) being the default. bsize(150) would increase the size of the labels, whereas bsize(75) would decrease them. bsize() is also used with star (see gr7star) to set the text size of the observation titles. Also see the set textsize command in graph7.

Rescale (note capitalization) is used only in combination with by(). It requests that each by-group graph have its own scale. The default is to use the same scale across all graphs.

xsize(#) specifies the width, in inches, for printing the image. The default is 6 inches and can range from 1 to 20.

ysize(#) specifies the height, in inches, for printing the image. The default is 4 inches and can range from 1 to 20.

margin(#) is unique to graph7 using and specifies the margin to be placed around each graph as a percent of graphical area. The default is 0. margin(15) is generally a good selection.

title("text"), t1title("text"), t2title("text"), b1title("text"), b2title("text"), l1title("text"), l2title("text"), r1title("text"), and r2title("text") add titles to the graph and are detailed in gr7axes. With graph7 using these options can add titles to a graph after it is originally produced. They also provide marginal titles when combining several graphs.

Also see

Help: [G-2] graph7, gr7axes, gr7bar, gr7box, gr7color, gr7hist, gr7matrix, gr7oneway, gr7pie, gr7star, gr7sym, gr7twoway


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index