Graphics Reference
In-Depth Information
The descriptive text always concludes by telling you the name of the data file and
scheme used for making the graph. In this case, the data file was allstates.dta , and the
scheme was vg s2c.scheme . You can read the data file over the Internet by using the
vguse command, a command added to Stata when you install the online supplements;
see Appendix : Online supplements (382). If you are connected to the Internet, and your
Stata is fully up to date, you can simply type vguse allstates to use that file over
the Internet, and you can run the graph command shown to create the graph.
If you want your graphs to look like the ones in the topic, you can display them using
the same schemes. See Appendix : Online supplements (382) for information about how to
download the schemes used in this topic. Once you have downloaded the schemes, you can
then type the following in the Stata Command window:
. set scheme vg s2c
. vguse allstates
. graph twoway scatter propval100 ownhome, msymbol(Sh)
After you issue the set scheme vg s2c command, subsequent graph commands will
show graphs using the vg s2c scheme. If you prefer, you could add the scheme(vg sc2)
option to the graph command to specify the scheme used just for that graph; for example,
. graph twoway scatter propval100 ownhome, msymbol(Sh) scheme(vg s2c)
In general, all commands and options are provided in their complete form. Commands
and options are generally not abbreviated. However, for purposes of typing, you may wish
to use abbreviations. The previous example could have been abbreviated to
. gr tw sc propval100 ownhome, m(Sh)
and even the gr could have been omitted, leaving
. tw sc propval100 ownhome, m(Sh)
The tw could also have been omitted, leaving
. sc propval100 ownhome, m(Sh)
For guidance on appropriate abbreviations, consult [ G ] graph .
I should note that, while this topic is designed for creating graphs in Stata version 8 and
beyond, many of the examples take advantage of numerous enhancements that have been
released as online updates subsequent to the initial version 8 release. As a result, some
features will either look different or may not work at all in Stata 8.0 or 8.1. Therefore, it is
very important that your copy of Stata be fully up to date. Please verify that your copy of
Stata is up to date and obtain any free updates; to do this, enter Stata, type
. update query
and follow the instructions. After the update is complete, you can use the help whatsnew
command to learn about the updates you have just received, as well as prior updates
documenting the evolution of Stata. Because Stata sometimes evolves beyond the printed
manual, you might find that some commands or options are documented via the online help
but not in your manual. For example, graph twoway tsline was released after the printed
manual and, as of the first printing of this topic, is only documented via the online help
( help tsline ).
The electronic form of this topic is solely for direct use at UCLA and only by faculty, students, and staff of UCLA.
Search WWH ::




Custom Search