Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Eviews5 / EViews5 / Docs / EViews 5 Command Ref.pdf
Скачиваний:
91
Добавлен:
23.03.2015
Размер:
5.23 Mб
Скачать

Labeling Graphs—81

There are three methods for displaying the confidence intervals in boxplots. They may be notched, shaded, or not drawn at all, which you may specify using one of the supported keywords (notch, shade, none). For example,

boxgraph01.setbpelem ci(notch)

draws the confidence intervals in BOXGRAPH01 as notches.

Modifying the boxplot horizontal axis

The bplabel (p. 231) command for boxplots is similar to the datelabel command in time plots (see “Modifying the date/time axis” beginning on page 71). Use it to specify the frequency or alignment of labels on the horizontal axis. Provide the step method you wish to use, and optionally a step or alignment number. For example,

boxgraph02.bplabel interval(ends)

labels the first and last boxes in BOXGRAPH02. To label every fiftieth box, aligned with the tenth box:

boxgraph02.bplabel interval(cust, 50, 10)

A boxplot's horizontal scale can be modified further by placing the text labels at an angle, changing the text itself, or selectively hiding any of the labels. Using the bplabel command,

boxgraph02.bplabel angle(60) label(10, "First") -label(60)

sets the labels in BOXGRAPH02 to a 60 degree angle, changes the tenth box label to “First”, and hides the sixtieth label.

Labeling Graphs

As with all EViews objects, graphs have a label view to display and edit information such as the graph name, last modified date, and remarks. To modify or view the label information, use the label (p. 330) command:

graph12.label(r) Data from CPS 1988 March File

This command shows the label view, and the “r” option appends the text “Data from CPS 1988 March File” to the remarks field of GRAPH12.

To return to the graph view, use the graph keyword:

graph12.graph

All changes made in label view will be saved when the graph is saved.

82—Chapter 5. Working with Graphs

Printing Graphs

A graph may be printed using the print (p. 409) command. For example,

print graph11 graph12

prints GRAPH11 and GRAPH12 on a single page.

In addition, many graph commands and graph views of objects include a print option. For example, you can create and simultaneously print a line graph GRA1 of SER1 using the “p” option:

graph gra1.line(p) ser1

You should check the individual commands for availability of this option.

Exporting Graphs to Files

You may use the save (p. 430) proc of a graph object to save the graph as a Windows metafile (.wmf), Enhanced Windows metafile (.emf), or Postscript file (.eps).

You must specify a file name and file type, and may also provide the file height, width, units of measurement, and color use. Postscript files also allow you to save the graph with or without a bounding box and to specify portrait or landscape orientation. For instance,

graph11.save(t=postscript, u=cm, w=12, -box) MyGraph1

saves GRAPH11 in the default directory as a Postscript file MyGraph1.eps, with a width of 12 cm and no bounding box. The height is determined by holding the aspect ratio of the graph constant. Similarly,

graph11.save(t=emf, u=pts, w=300, h=300, -c) c:\data\MyGraph2

saves GRAPH11 as an Enhanced Windows metafile MYGRAPH2.EMF. The graph is saved in black and white, and scaled to 300 × 300 points.

Graph Summary

See “Graph” (p. 161) for a full listing of procs that may be used to customize graph objects, and for a list of the graph type commands.

Соседние файлы в папке Docs