• No results found

2. Descriptive statistics in EViews

N/A
N/A
Protected

Academic year: 2021

Share "2. Descriptive statistics in EViews"

Copied!
23
0
0

Loading.... (view fulltext now)

Full text

(1)

2. Descriptive statistics in EViews

Features of EViews:

Data processing

(importing, editing, handling, exporting data)

Basic statistical tools

(descriptive statistics, inference, graphical tools)

Regression analysis

Time series analysis

Specification diagnostics, specification testing

(2)

2.1. Introduction to EViews

Fundamental concept behind EViews:

EViews is based on objects Some typical EViews objects:

Data series (single: series, collection of series: groups)

graphs

equations

How to enter EViews commands:

(3)
(4)

Basis of all EViews actions:

workfile

Definition of a workfile:

Container for all EViews objects with which you want to work (series, graphs, equations)

Features of a workfile:

Prespecified data frequency

(5)

Creating an EViews-workfile:

Either by typing the command create

Or by clicking through the menu items File/New/ Workfile

−→ dialogue requesting two pieces of information: (1) Data frequency

(6)

Data frequency and data representation Frequency Representation annual 2014, 2015, etc. semi-annual 2015:1, 2015:2 quarterly 2015:1, ... , 2015:4 monthly 2015:01, ... , 2015:12 weekly mm/dd/yyyy, e.g. 03/26/2015

daily (5 days weeks) mm/dd/yyyy

daily (7 days weeks) mm/dd/yyyy

(7)

Generating data series:

Manual data input

(invoking the EViews data editor by the command data)

Importing data from external data bases (e.g. from Excel, Lotus, ...)

Afterwards, we may use data series

to generate graphs

(8)

Two fundamental EViews concepts:

Transformating data series (via the genr command)

Setting the active sample (via the smpl command)

Objective of many data transformations:

(9)

Example:

Assume we are given the following series in EViews:

EX RATE: the nominal Euro-USD exchange rate

P EURO: the overall price level in Euroland

P US: the overall price level in the US Creating the real exchange-rate series:

(10)

Some operators and functions for the genr command Operator Meaning Example

+ Sum

- Difference

* Product

/ Ratio

^ Power genr H = (A+B/(H+K))^2

log(x) Natural log genr Z = log(X) exp(x) Natural exp

abs(x) Absolute value

sqr(x) Square root

sin(x) Sine

(11)

Lagged values (lag operator, lags):

Let Pt denote an overall price level at date t

The inflation rate πt between the dates t 1 and t is defined as

πt = Pt Pt−1 Pt1

Lag operator in EViews:

Let P be the price-level series in EViews

(12)

Setting the active sample:

Sometimes, it may not be reasonable to consider all obser-vations of a series in statistical operations

Via the smpl command we are able to restrict the data range to be processed

Example:

Assume that your worfile contains yearly GDP data between 1950 and 2015:

If you only need to consider the time period 1970 until 2010, you set

smpl 1970 2010

(13)

Remarks:

The smpl command allows us to further restrict our data base via the if statement

If you only need to analyze the years between 1970 and 2010, in which the inflation rate exceeded 2%, you set

(14)

2.2. Descriptive statistics

Notation:

Consider the data series x1, . . . , xT

T is the number of observations, xt is the t-th observation

(15)

Example:

Prices (in euros) of the mutual fund DEKALUX-JAPAN during the calender weeks #10 and #11 in 2002

Date t xt x(t) 03/04/2002 1 527.54 x(3) 03/05/2002 2 523.79 x(2) 03/06/2002 3 521.92 x(1) 03/07/2002 4 540.91 x(7) 03/08/2002 5 551.68 x(9) 03/11/2002 6 556.54 x(10) 03/12/2002 7 543.45 x(8) 03/13/2002 8 530.52 x(4) 03/14/2002 9 534.60 x(5)

(16)

2.2.1. Histogram and empirical cumulative

distri-bution function

Definition 2.1: (Histogram)

The histogram divides the series range (the distance between the maximum and minimum values) into a number of equal length intervals (bins) and displays a count of the number of observa-tions that fall into each bin.

Definition 2.2: (Empirical cumulative distribution function)

Given the data series x1, . . . , xT, for every x R the empirical cumulative distribution function FT : R [0,1] is defined as

(17)

Histogram with descriptive statistics in EViews 0 1 2 3 520 525 530 535 540 545 550 555 560 Series: DEKALUX Sample 3/04/2002 3/15/2002 Observations 10 Mean 536.8990 Median 536.3200 Maximum 556.5400 Minimum 521.9200 Std. Dev. 11.51973 Skewness 0.340804 Kurtosis 2.018182 Jarque-Bera 0.595232 Probability 0.742587

(18)

Empirical cumulative distribution function in EViews 0.0 0.2 0.4 0.6 0.8 1.0 524 528 532 536 540 544 548 552 556 P robabi li ty DEKALUX

(19)

2.2.2. Measures of a single series

Minimum, maximum:

Formulae: xmin = x(1), xmax = x(T)

EViews commands: =@min(DEKALUX), =@max(DEKALUX)

Arithmetic mean: Formula: x = 1 T · (x1 + x2 + . . . + xT) = 1 T · T X t=1 xt

(20)

Median: Formula: xmed =    x([T+1]/2) , if T odd 1 2 · h x(T /2) + x([T+2]/2)i , if T even

EViews command: =@median(DEKALUX)

Variance, standard deviation:

Formulae: s2 = 1 T 1· T X t=1 (xt x)2 , s = v u u u t 1 T 1 · T X t=1 (xt x)2

(21)

Skewness: Formula: xskew = 1 T T X t=1   q1 xt x T PT t=1 (xt x)2    3

EViews command: =@skew(DEKALUX)

Kurtosis: Formula: xkurt = 1 T T X t=1   q1 xt x T PT t=1(xt x)2    4

(22)

2.2.3. Covariance and correlation

Now:

Assume that you have collected pairwise observations (x1, y1), . . . ,(xT, yT) for the two data series X and Y in EViews

Covariance: Formula: SXY = 1 T 1 T X t=1 (xt x)(yt y)

(23)

Correlation coefficient: Formula: RXY = SXY SX · SY = PT t=1(xt x)(yt y) rhPT t=1(xt x)2 i hPT t=1(yt y)2 i

References

Related documents

If we reject the null hypothesis, so the panel is partially homogeneous e.i heterogeneous intercepts homogeneous slope, and the model has individual effects as the form

„ No man born of woman shall harm Macbeth No man born of woman shall harm

Experiment  manipulated pitch accent type, comparing a broad focus control condition to two narrow focus conditions: with a contrastive or non-contrastive accent on the subject

The European knight carried a sword with a wide, single-fullered and double-edged blade, with rounded pommel and straight cross guard. When King Richard I of England (1157–1199)

This paper employs Wendy Griswold‘s cultural analysis framework to examine how changes in media forms over time shape cultural products, using case studies of professional

All formal academic appeals must be submitted in writing (or electronically via email for students enrolled in an online course) on an Academic Appeal Form to the

Life sciences venture capital investment is second only to software in California and is a significant contributor to California’s projected 60.1 percent share of all venture capital

out the State plan and in its administration and supervision, including a description of the method to be used to expand and improve services to handicapped individuals with the most