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

scale—433

scalar

Object Declaration

 

 

Declare a scalar object.

The scalar command declares a scalar object and optionally assigns a value.

Syntax

Command: scalar scalar_name[=assignment]

The scalar keyword should be followed by a valid name, and optionally, by an assignment. If there is no explicit assignment, the scalar will be initialized with a value of zero.

Examples

scalar alpha

declares a scalar object named ALPHA with value zero.

equation eq1.ls res c res(-1 to -4) x1 x2

scalar lm = eq1.@regobs*eq1.@r2

show lm

runs a regression, saves the nR2 as a scalar named LM, and displays its value in the status line at the bottom of the EViews window.

Cross-references

See “Scalar” on page 176 for a summary of the features of scalar objects in EViews.

scale

Graph Proc

 

 

Sets axis and data scaling characteristics for the graph.

By default, EViews optimally chooses the axes to fit the graph data.

Syntax

Graph Proc:

graph_name.scale(axis_id) options_list

The axis_id parameter identifies which of the axes the proc modifies. If no option is specified, the proc will modify all of the axes. axis_id may take on one of the following values:

left / l

Left vertical axis.

 

 

right / r

Right vertical axis.

434—Appendix B. Command Reference

bottom / b

Bottom axis for XY and scatter graphs (scat (p. 435),

 

xy (p. 556), xyline (p. 558), xypair (p. 561)).

 

 

top / t

Top axis for XY and scatter graphs (scat (p. 435), xy

 

(p. 556), xyline (p. 558), xypair (p. 561)).

 

 

all / a

All axes.

 

 

Note: the syntax of scale has changed considerably from version 4.1 of EViews (see, in particular axis (p. 217)). While not documented here, the previous options are still (for the most part) supported. However, we do not recommend using the old options as future support is not guaranteed.

Options

The options list may include any of the following options:

Data scaling options

linear

Linear data scaling (default).

 

 

linearzero

Linear data scaling (include zero when auto range

 

selection is employed).

 

 

log

Logarithmic scaling (does not apply to boxplots).

 

 

norm

Norm (standardize) the data prior to plotting (does not

 

apply to boxplots).

Axes scaling options

range(arg)

Specifies the endpoints for the scale: automatic choice

 

(“auto”), use the maximum and minimum values of the

 

data (“minmax”), set minimum to n1 and maximum to

 

n2 (“n1, n2”), e.g. “range(3, 9)”.

 

 

overlap / -over- [Overlap / Do not overlap] scales on dual scale graphs. lap

invert / -invert [Invert / do not invert] scale.

Note that the default settings are taken from the global defaults.

Examples

To set the right scale to logarithmic with manual range, you can enter:

graph1.scale(right) log range(10, 30)

Alternatively,

scat—435

graph1.scale -invert range(minmax)

draws duplicate inverted scales on the left and right axes which are defined to match the data range.

Cross-references

See Chapter 14, “Graphs, Tables, and Text Objects”, on page 413 of the User’s Guide for a discussion of graph options.

See also axis (p. 217), datelabel (p. 262), options (p. 375) and setelem (p. 449).

scat

Command || Graph Command | Group View | Matrix View | Rowvector View| Sym View

Display scatterplot graph of object, or change existing graph object type to scatterplot (if possible).

By default, the first series or column of data will be located along the horizontal axis, and the remaining data on the vertical axis. You may optionally choose to plot the data in pairs, where the first two series or columns are plotted against each other, the second two series or columns are plotted against each other, and so forth.

Syntax

Command:

scat(options) arg1 [arg2 arg3 ...]

Object View:

group_name.scat(options)

Graph Proc:

graph_name.scat(options)

If used as a command, follow the keyword by a list of series and group objects, or by a matrix object. There must be at least two series or columns in the data to be graphed.

Scatterplots are simply XY plots (see xy (p. 556)) with symbols turned on, and lines turned off (see setelem (p. 449)).

Options

Template and printing options

o= template Use appearance options from the specified template. template may be a predefined template keyword (‘default” - current global defaults, “classic”, “modern”, “reverse”, “midnight”, “spartan”, “monochrome”) or a graph in the workfile.

436—Appendix B. Command Reference

t=graph_name Use appearance options and copy text and shading from

 

the specified graph.

 

 

b / -b

[Apply / Remove] bold modifiers of the base template

 

style specified using the “o=” option above.

 

 

w / -w

[Apply / Remove] wide modifiers of the base template

 

style specified using the “o=” option above.

 

 

p

Print the scatterplot graph.

 

 

The options which support the “-” may be proceeded by a “+” or “-” indicating whether to turn on or off the option. The “+” is optional.

Note that use of the template option will override the symbol setting.

Scale options

a (default)

Automatic single scale.

 

 

b

Plot series or columns in pairs (the first two against

 

each other, the second two against each other, and so

 

forth).

 

 

n

Normalized scale (zero mean and unit standard devia-

 

tion). May not be used with the “s” option.

 

 

d

Dual scaling with no crossing.

 

 

x

Dual scaling with possible crossing.

 

 

mDisplay XY plots in multiple graphs (will override the “s” option). Not for use with an existing graph object.

Panel options

The following options apply when graphing panel structured data.

scat—437

panel=arg

Panel data display: “stack” (stack the cross-sections),

(default taken

“individual” or “1” (separate graph for each cross-sec-

from global settion), “combine” or “c” (combine each cross-section in

tings)

single graph; one time axis), “mean” (plot means

 

across cross-sections), “mean1se” (plot mean and +/-

 

1 standard deviation summaries), “mean2sd” (plot

 

mean and +/- 2 s.d. summaries), “mean3sd” (plot

 

mean and +/- 3 s.d. summaries), “median” (plot

 

median across cross-sections), “med25” (plot median

 

and +/- .25 quantiles), “med10” (plot median and +/-

 

.10 quantiles), “med05” (plot median +/- .05 quan-

 

tiles), “med025” (plot median +/- .025 quantiles),

 

“med005” (plot median +/- .005 quantiles), “med-

 

mxmn” (plot median, max and min).

Examples

scat unemp inf want

produces an UNTITLED graph object containing a scatter plot, with UNEMP on the horizontal and INF and WANT on the vertical axis.

group med age height weight

med.scat(t=scat2)

produces a scatter plot view of the group object MED, using the graph object SCAT2 as a template.

group pairs age height weight length

pairs.scat(b)

produces a scatter plot view with AGE plotted against HEIGHT, and WEIGHT plotted against LENGTH.

If there is an existing graph GRAPH01, the expression:

graph01.scat(b)

changes its type to a scatterplot with data plotted in pairs (if possible), with the remaining XY graph settings at their default values.

Cross-references

See Chapter 14, “Graphs, Tables, and Text Objects”, on page 413 of the User’s Guide for a discussion of graphs and templates.

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