Free Essay

Eviews

In:

Submitted By Ann11
Words 24327
Pages 98
Financial Econometrics
With Eviews
Roman Kozhan

Download free books at

Roman Kozhan

Financial Econometrics

Download free eBooks at bookboon.com
2

Financial Econometrics – with EViews
© 2010 Roman Kozhan & Ventus Publishing ApS
ISBN 978-87-7681-427-4

To my wife Nataly

Download free eBooks at bookboon.com
3

Contents

Financial Econometrics

Contents

Preface

6

1
1.1
1.2
1.3
1.4

Introduction to EViews 6.0
Workfiles in EViews
Objects
Eviews Functions
Programming in Eviews

7
8
10
18
22

2
2.1
2.2
2.3

Regression Model
Introduction
Linear Regression Model
Nonlinear Regression

34
34
34
52

3
3.1
3.2
3.3

Univariate Time Series: Linear Models
Introduction
Stationarity and Autocorrelations
ARMA processes

54
54
54
59

www.sylvania.com

We do not reinvent the wheel we reinvent light. Fascinating lighting offers an infinite spectrum of possibilities: Innovative technologies and new markets provide both opportunities and challenges.
An environment in which your expertise is in high demand. Enjoy the supportive working atmosphere within our global group and benefit from international career paths. Implement sustainable ideas in close cooperation with other specialists and contribute to influencing our future. Come and join us in reinventing light every day.

Light is OSRAM

Download free eBooks at bookboon.com
4

Click on the ad to read more

Contents

Financial Econometrics

4
4.1
4.2
4.3
4.4

Stationarity and Unit Roots Tests
Introduction
Unit Roots tests
Stationarity tests
Example: Purchasing Power Parity

69
69
69
74
75

5
5.1
5.2
5.3
5.4
5.5

Univariate Time Series: Volatility Models
Introduction
The ARCH Model
The GARCH Model
GARCH model estimation
GARCH Model Extensions

80
80
80
83
86
87

6
Multivariate Time Series Analysis
6.1 Vector Autoregression Model
6.2 Cointegration

Bibliography

95
95
103

360° thinking 117

.

360° thinking .

360° thinking .

Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Download free eBooks at bookboon.com

Discover the truth5at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Click on the ad to read more

© Deloitte & Touche LLP and affiliated entities.

D

Preface

Financial Econometrics

Preface
The aim of this textbook is to provide a step-by-step guide to financial econometrics using EViews 6.0 statistical package. It contains brief overviews of econometric concepts, models and data analysis techniques followed by empirical examples of how they can be implemented in EViews.
This book is written as a compendium for undergraduate and graduate students in economics and finance. It also can serve as a guide for researchers and practitioners who desire to use EViews for analysing financial data. This book may be used as a textbook companion for graduate level courses in time series analysis, empirical finance and financial econometrics.
It is assumed that the reader has a basic background in probability theory and mathematical statistics
The material covered in the book includes concepts of linear regression, univariate and multivariate time series modelling and their implementation in EViews.
Chapter 1 briefly introduces commands, structure and programming language of the EViews package. Chapter 2 provides an overview of the regression analysis and its inference. Chapters 3 to 5 cover some topics of univariate time series analysis including linear models, GARCH models of volatility, unit root tests. Chapter 6 introduces modelling of multivariate time series.

6

Download free eBooks at bookboon.com
6

Introduction to EViews 6.0

Financial Econometrics

Chapter 1
Introduction to EViews 6.0
EViews is a simple, interactive econometrics package which proves many tools used in econometrics. It provides users with several convenient ways of performing analysis including a Windows and a command line interfaces. Many operations that can be implemented using menus may also be entered into the command window, or placed in programs for batch processing. The possibility of using interactive features like windows, buttons and menus makes EViews a user-friendly software.
In this chapter we briefly introduce you main features of the language, will show you the use of some important commands which will be used further in this textbook. We will start with the interactive Windows interface and then go into more detailed description about the EViews’ batch processing language and advanced programming features.

We will turn your CV into an opportunity of a lifetime

7
Do you like cars? Would you like to be a part of a successful brand?
We will appreciate and reward both your enthusiasm and talent.
Send us your CV. You will be surprised where it can take you.

Send us your CV on www.employerforlife.com Download free eBooks at bookboon.com
7

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

1.1

Workfiles in EViews

EViews’ design allows you to work with various types of data in an intuitive and convenient way. We start with the basic concepts of how to working with datasets using workfiles, and describing simple methods to get you started on creating and working with workfiles in EViews.
In the majority of cases you start your work in EViews with a workfile – a container for EViews objects. Before you perform any tasks with EViews’ objects you first have to either create a new workfile or to load an existing workfile from the disc. In order to create a new workfile you need to provide and information about its structure. Select File/New/Workfile from the main menu to open the Workfile Create dialog. On the left side of the dialog is a combo box for describing the underlying structure of your dataset. You have to choose between three options regarding the structure of your data – the Dated - regular frequency, the Unstructured, and the
Balanced Panel settings. Dated - regular frequency is normally used to work with a simple time series data, Balanced Panel is used for a simple panel dataset and
Unstructured options is used for all other cases.
For the Dated - regular frequency, you may choose among the following options:
Annual, Semi-annual, Quarterly, Monthly, Weekly, Daily - 5 day week, Daily - 7 day week and Integer date. EViews will also ask you to enter a Start date and End date for your workfile. When you click on OK, EViews will create a regular frequency workfile with the specified number of observations and the associated identifiers.
The Unstructured data simply uses integer identifiers instead of date identifiers.
You would use this type of workfile while performing a crossectional analysis. Under this option you would only need to enter the number of observations.
The Balanced Panel entry provides a method of describing a regular frequency panel data structure. Panel data is the term that we use to refer to data containing observations with both a group (cross-section) and time series identifiers. This entry may be used when you wish to create a balanced structure in which every crosssection follows the same regular frequency with the same date observations.
Under this option you should specify a desired Frequency, a Start and End date, and Number of cross sections.
Another method of creating an EViews workfile is to open a non-EViews data source and to read the data into an new EViews workfile. To open a foreign data source, first select File/Open/Foreign Data as Workfile. First, EViews will open a series of dialogs asking you to describe and select data to be read. The data will be read into the new workfile, which will be resized to fit. If there is a single date series
8
Download free eBooks at bookboon.com
8

Introduction to EViews 6.0

Financial Econometrics

in the data, EViews will attempt to restructure the workfile using the date series.
A typical workfile view is given in Figure 1.1.
Figure 1.1: Workfile in EViews

Workfiles contain the EViews objects and provide you an access to your data and tools for working with this data.
Below the titlebar of a workfile is a button bar that provides you with easy access to some useful workfile operations. These buttons are simply shortcuts to items that may be accessed from the main EViews menu. Below the toolbar are two lines of status information where EViews displays the range of the workfile, the current sample (the range of observations that are to be used in calculations), and the display filter (rule used in choosing a subset of objects to display in the workfile window). You may change the range, sample, and filter by double clicking on these labels and entering the relevant information in the dialog boxes. The contents of your workfile page is provided in in the workfile directory. You can find there all named objects, sorted by name, with an icon showing the object type.
Push the Save button on the workfile toolbar to save a copy of the workfile on disk. You can also save a file using the File/ Save As or File/Save choices from the main menu. By default, EViews will save your data in the EViews workfile format, the extension ".wf1". You may also choose to save the data in your workfile in a foreign data format by selecting a different format in the combo box.
When you click on the Save button, EViews will display a dialog showing the current global default options for saving the data in your workfile. You should choose between saving your series data in either Single precision or Double precision.
Single precision will create smaller files on disk, but saves the data with fewer digits of accuracy (7 versus 16). You may also choose to save your data in compressed or non-compressed form.
9
Download free eBooks at bookboon.com
9

Introduction to EViews 6.0

Financial Econometrics

1.2

Objects

All information in EViews is stored in objects. Each object consists of a collection of information related to a particular area of analysis. For example, a series object is a collection of information related to a set of observations on a particular variable.
An equation object is a collection of information related to the relationship between a collection of variables. Together with the data information, EViews also associates procedures which can be used to process the data. For example, an equation object contains all of the information relevant to an estimated relationship, you can examine results, perform hypothesis and specification tests, or generate forecasts at any time.
Managing your work is simplified since only a single object is used to work with an entire collection of data and results.
Each object contains various types of information. For example, series, matrix, vector, and scalar objects contain numeric data while equations and systems contain complete information about the specification of the equation or system, the estimation results. Graphs and tables contain numeric, text, and formatting information.
Since objects contain various kinds of data, you will work with different objects in different ways.

I joined MITAS because
I wanted real responsibili�
I joined MITAS because
I wanted real responsibili�

Real work
International
Internationa opportunities al �ree wo placements work or

10

�e Graduate Programme for Engineers and Geoscientists

Maersk.com/Mitas www.discovermitas.com M

Month 16
I was a construction
M
supervisor ina cons
I was the North Sea super advising and the No he helping foremen advis s Real work solve problems he helping f
International
Internationa opportunities al �ree wo placements work or s solve p

Download free eBooks at bookboon.com
10

�e for Engin

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

EViews provides you with different tools for each object. These tools are views and procedures which often display tables or graphs in the object’s window. Using procedures you can create new objects. For example, equation objects contain procedures for generating new series containing the residuals, fitted values, or forecasts from the estimated equation. You select procedures from the Proc menu and views from the View on the object’s toolbar or from the EViews main menu.
There are a number of different types of objects, each of which serves a unique function. Most objects are represented by a unique icon which is displayed in the workfile window. The basic object icons are:
Figure 1.2: Object Icons

In order to create an object, create or loaded a workfile first and then select
Object/New Object from the main menu. You will see the New Object dialog box where you can click on the type of object you want to create. For some object types, a second dialog box will open prompting you to describe your object in more detail.
For example, if you select Equation, you will see a dialog box prompting you for additional information.
Once you have selected your object, you can open it by double clicking anywhere in the highlighted area. If you double click on a single selected object, you will open an object window. If you select multiple graphs or series and double click, a pop-up menu appears, giving you the option of creating and opening new objects (group, equation, VAR, graph) or displaying each of the selected objects in its own window. Note that if you select multiple graphs and double click or select
View/Open as One Window, all of the graphs will be merged into a single graph and displayed in a single window. Other multiple item selections are not valid, and will either issue an error or will simply not respond when you double click. When you open an object, EViews will display the view that was displayed the last time the object was opened (if an object has never been opened, EViews will use a default view). The exception to this general rule is for those views that require significant computational time. In this latter case, the current view will revert to the default.
An alternative method of selecting and opening objects is to "show" the item.
Click on the Show button on the toolbar, or select Quick/Show from the menu and
11
Download free eBooks at bookboon.com
11

Introduction to EViews 6.0

Financial Econometrics

type in the object name or names. Showing an object works exactly as if you first selected the object or objects, and then opened your selection.
Object windows are the windows that are displayed when you open an object or object container. An object’s window will contain either a view of the object, or the results of an object procedure. One of the more important features of EViews is that you can display object windows for a number of items at the same time.
Let us look again at a typical object window:
Figure 1.3: Object Window in EViews

Here, we see the series window for RETURNS. At the top of the window there is a toolbar containing a number of buttons that provide easy access to frequently used menu items. These toolbars will vary across objects. There are several buttons that are found on all object toolbars:
• View button lets you change the view that is displayed in the object window.
The available choices will differ, depending upon the object type.
• Proc button provides access to a menu of procedures that are available for the object. • Object button lets you manage your objects. You can store the object on disk, name, delete, copy, or print the object.
• Print button lets you print the current view of the object (the window contents).
• Name button allows you to name or rename the object.
12
Download free eBooks at bookboon.com
12

Introduction to EViews 6.0

Financial Econometrics

• Freeze button creates a new object graph, table, or text object out of the current view.
There are two distinct methods of duplicating the information in an object: copying and freezing. If you select Object/Copy from the menu, EViews will create a new untitled object containing an exact copy of the original object. By exact copy, we mean that the new object duplicates all the features of the original (except for the name). It contains all of the views and procedures of the original object and can be used in future analyses just like the original object. You may also copy an object from the workfile window. Simply highlight the object and click on Object/Copy
Selected or right mouse click and select Object/Copy, then specify the destination name for the object.
The second method of copying information from an object is to freeze a view of the object. If you click Object/Freeze Output or press the Freeze button on the object’s toolbar, a table or graph object is created that duplicates the current view of the original object. Freezing the view makes a copy of the view and turns it into an independent object that will remain even if you delete the original object. A frozen view shows a snapshot of the object at the moment you pushed the button.
The primary feature of freezing an object is that the tables and graphs created by freezing may be edited for presentations or reports. Frozen views do not change when the workfile sample or data change.

13
Download free eBooks at bookboon.com
13

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

To delete an object or objects from your workfile, select the object or objects in the workfile directory and click Delete or Object/Delete Selected on the workfile toolbar. Series
An series object contains a set of observations on a numeric variable. Associated with each observation in the series is a date or observation label. Note that the series object may only be used to hold numeric data. If you wish to work with alphanumeric data, you should employ alpha series.
You can create a numeric series by selecting Object/New Object from the menu, and then to select Series. EViews will open a spreadsheet view of the new series object with all of the observations containing "NA" (the missing value). You may then edit or use expressions to assign values for the series. A second method of creating a series is to generate the series using mathematical expressions. Click on
Quick/Generate Series in the main EViews menu, and enter an expression defining the series.
Lastly, you may create the series by entering a series command in the command window. Entering an expression of the form: series returns=expression creates a series with the name returns and assigns the expression to each observation.
You can edit individual values of the data in a series. First, open the spreadsheet view of the series. Next, make certain that the spreadsheet window is in edit mode (you can use the Edit +/– button on the toolbar to toggle between edit mode and protected mode). To change the value for an observation, select the cell, type in the value, and press ENTER.
You can also insert and delete observations in the series. First, click on the cell where you want the new observation to appear. Next, right click and select
Insert Obs or Delete Obs from the menu. You will see a dialog asking how many observations you wish to insert or delete at the current position and whether you wish to insert observations in the selected series or in all of the series in the group.
If you choose to insert a single observation, EViews will insert a missing value at the appropriate position and push all of the observations down so that the last observation will be lost from the workfile. If you wish to preserve this observation, you will have to expand the workfile before inserting observations. If you choose to delete an observation, all of the remaining observations will move up, so that you will have a missing value at the end of the workfile range.
Groups
14
Download free eBooks at bookboon.com
14

Introduction to EViews 6.0

Financial Econometrics

A group is a list of series names that provides simultaneous access to all of the elements in the list. With a group, you can refer to sets of variables using a single name. Thus, a set of variables may be analyzed using the group object, rather than each one of the individual series. Once a group is defined, you can use the group name in many places to refer to all of the series contained in the group. You would normally create groups of series when you wish to analyze or examine multiple series at the same time. For example, groups are used in computing correlation matrices, testing for cointegration and estimating a VAR or VEC, and graphing series against one another.
There are several ways to create a group. Perhaps the easiest method is to select Object/New Object from the main menu or workfile toolbar, click on Group.
You should enter the names of the series to be included in the group, separated by spaces, and then click OK. A group window will open showing a spreadsheet view of the group.
If you apply an operation to a group, EViews will automatically evaluate the expressions for each observation and display the results as if they were an ordinary series. 15
Download free eBooks at bookboon.com
15

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

An equivalent method of creating a group is to select Quick/Show, or to click on the Show button on the workfile toolbar, and then to enter the list of series, groups and series expressions to be included in the group. You can also create an empty group that may be used for entering new data from the keyboard or pasting data copied from another Windows program.
Samples
One of the most important concepts in EViews is the sample of observations.
The sample is the set of observations in the workfile used for performing statistical procedures. Samples may be specified using ranges of observations and "if conditions" that observations must satisfy to be included. For example, you can tell EViews that you want to work with observations from 1973M1 to 1990M12 and
1995M1 to 20066M12. Or you may want to work with data from 1973M1 to 1978M12 where observations in the Returns series are positive. When you create a workfile, the workfile sample is set initially to be the entire range of the workfile. The workfile sample tells EViews what set of observations you wish to use for subsequent operations. You can always determine the current workfile sample of observations by looking at the top of your workfile window. Here the MYDATA workfile consists of
408 observations from January 1973 to December 2006. The current workfile sample uses a subset of those 72 observations between 1973M01 and 1978M12 for which the value of the Returns series is positive.
There are four ways to set the workfile sample: you may click on the Sample button in the workfile toolbar, you may double click on the sample string display in the workfile window, you can select Proc/Set Sample from the main workfile menu, or you may enter a smpl command in the command window.
EViews provides special keywords that may make entering sample date pairs easier. First, you can use the keyword @all, to refer to the entire workfile range. In the workfile above, entering @all in the dialog is equivalent to typing "1973M12006M12".
Furthermore, you may use @first and @last to refer to the first and last observation in the workfile. Thus, the three sample specifications for the above workfile:
@all
@first 2006m12
19733m1 @last are identical.

1

1

You may use the IEEE standard format, “YYYY-MM-DD”, which uses a four-digit year, followed by a dash, a two-digit month, a second dash, and a two-digit day. The presence of a dash in the format means that you must enclose the date in quotes for EViews to accept this format.
For example: "1991-01-03" "1995-07-05" will always be interpreted as January 3, 1991 and July

16
Download free eBooks at bookboon.com
16

Introduction to EViews 6.0

Financial Econometrics

Sample Commands
EViews allows you to add conditions to the sample specification. In this case the sample is the intersection of the set of observations defined by the range pairs in the upper window and the set of observations defined by the if conditions. This can be done by typing the expression: smpl 1973m1 1978m12 if returns>0 in the command window. You should see the sample change in the workfile window.
Sample range elements may contain mathematical expressions to create date offsets. This feature can be particularly useful in setting up a fixed width window of observations. For example, in the regular frequency monthly workfile above, the sample string: 1973m1 1973m1+11 defines a sample that includes the 12 observations in the calendar year beginning in 1973M1. The offsets are perhaps most useful when combined with the special keywords to trim observations from the beginning or end of the sample. For example, to drop the first observation in your sample, you may use the sample statement: smpl @first+1 @last
Accordingly, the following commands generate a cumulative returns series from the price levels one: smpl @first @first series returns = 0 smpl @first+1 @last returns = returns(-1) + log(price) - log(price(-1))
The first two commands initialize the cumulative returns series at 0, the last two commands compute them recursively all remaining dates. Later we will see how sample offsets can be used to perform the rolling window estimation.
EViews provides you with a method of saving sample information in an object which can then be referred to by name. To create a sample object, select Object/New
Object from the main menu or the workfile toolbar. When the New Object dialog appears, select Sample and, optionally provide a name. Click on OK and EViews will open the sample object specification dialog which you should fill out. The sample object now appears in the workfile directory with a double-arrow icon. To declare a sample object using a command, simply issue the sample declaration, followed by the name to be given to the sample object, and then the sample string:
5, 1995.

17
Download free eBooks at bookboon.com
17

Introduction to EViews 6.0

Financial Econometrics

sample mysample 1973m1 1978m12 if returns>0
EViews will create the sample object MYSAMPLE which will use observations between 1973:01 and 1978:12, where the cumulative returns are positive.
You may use a previously defined sample object directly to set the workfile sample. Simply open a sample object by double clicking on the name or icon. You can set the workfile sample using the sample object, by entering the smpl command, followed by the sample object name. For example, the command: smpl mysample will set the workfile sample according to the rules contained in the sample object
MYSAMPLE.

1.3
1.3.1

Eviews Functions
Operators

All of the operators described below may be used in expressions involving series and scalar values. When applied to a series expression, the operation is performed for each observation in the current sample.

Excellent Economics and Business programmes at:

“The perfect start of a successful, international career.”
CLICK HERE

to discover why both socially and academically the University of Groningen is one of the best

www.rug.nl/feb/education

places for a student to be

18

Download free eBooks at bookboon.com
18

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

Table 1.1: Operators
Expression

Operator Description

+

add, x+y, adds the contents of X and Y



subtract, x–y, subtracts the contents of Y from X

*

multiply, x*y, multiplies the contents of X by Y

/

divide, x/y, divides the contents of X by Y



raise to the power, x∧ y, raises X to the power of Y

>

greater than, x>y, takes the value 1 if X exceeds Y, and 0 otherwise

<

less than, x 100 and !time < 200 then !age = 1/!time else !age = 0 endif
26
Download free eBooks at bookboon.com
26

Introduction to EViews 6.0

Financial Econometrics

The FOR Loop
The for loop allows you to repeat a set of commands for different values of a control or string variable. The FOR loop begins with a for statement and ends with a next statement. Any number of commands may appear between these two statements. The syntax of the FOR statement differs depending upon whether it uses control variables or string variables.
FOR Loops with Control Variables To repeat statements for different values of a control variable, the for statement involves setting a control variable equal to an initial value, followed by the word to, and then an ending value. After the ending value you may include the word step followed by a number indicating by how much to change the control variable each time the loop is executed. If you do not include step, the step is assumed to be 1. For example, for !j=1 to 10 vector(10) weights(!j)=returns(!j)/stddev(!j) next The for loop is executed first for the initial value, unless that value is already beyond the terminal value. After it is executed for the initial value, the control variable is incremented by step and EViews compares the variable to the limit. If the limit is passed, execution stops.

Join the best at the Maastricht University
School of Business and
Economics!

Top master’s programmes
•  3rd place Financial Times worldwide ranking: MSc
3
International Business
• 1st place: MSc International Business
• 1st place: MSc Financial Economics
• 2nd place: MSc Management of Learning
• 2nd place: MSc Economics
•  nd place: MSc Econometrics and Operations Research
2
•  nd place: MSc Global Supply Chain Management and
2
Change
Sources: Keuzegids Master ranking 2013; Elsevier ‘Beste Studies’ ranking 2012;
Financial Times Global Masters in Management ranking 2012

Visit us and find out why we are the best!
Master’s Open Day: 22 February 2014

Maastricht
University is the best specialist university in the
Netherlands
(Elsevier)

www.mastersopenday.nl

27
Download free eBooks at bookboon.com
27

Click on the ad to read more

Introduction to EViews 6.0

Financial Econometrics

One important use of FOR loops with control variables is to change the sample.
If you add a control variable to a date in a smpl command, you will get a new date as many observations forward as the current value of the control variable. Here is a
FOR loop that gradually increases the size of the sample and computes an average returns: for !i=1 to 60 smpl 1973m1 1974m1+!i scalar avret!i = @mean(returns) next
One other important case where you will use loops with control variables is in accessing elements of a series or matrix objects. For example,
!rows=@rows(vec1)
vector cumsum1=vec1 for !i=2 to !rows cumsum1(!i)=cumsum1(!i-1)+vec1(!i) next computes the cumulative sum of the elements in the vector vec1 and saves it in the vector cusum1. To access an individual element of a series, you will need to use the
@elem function and @otod to get the desired element for !i=2 to !rows cumsum1(!i) = @elem(ser1, @otod(!i)) next
The @otod function returns the date associated with the observation index (counting from the beginning of the workfile), and the @elem function extracts the series element associated with a given date.
You can nest for loops to contain loops within loops. The entire inner for loop is executed for each successive value of the outer for loop. For example: matrix(25,10) xx for !i=1 to 25 for !j=1 to 10 xx(!i,!j)=(!i-1)*10+!j next next FOR Loops with String Variables When you wish to repeat statements for different values of a string variable, you can use the FOR loop to let a string variable
28
Download free eBooks at bookboon.com
28

Introduction to EViews 6.0

Financial Econometrics

range over a list of string values. Give the name of the string variable followed by the list of values. For example, for %y usdgbp usdjpy series %yrets = dlog(%y) next creates the returns series of two exchange rates series usdgbpret = dlog(usdgbp) series usdjpyret = dlog(usdjpy)
You can put multiple string variables in the same for statement – EViews will process the strings in sets.
For example: for %y %z usdgbp usdjpy nzdusd audusd equation e%y.ls %y c %z next In this case, the elements of the list are taken in groups of three. The loop is executed two times for the different sample pairs: equation eusdgbp.ls usdgbp c usdjpy equation eusdgbp.ls nzdusd c audusd
The WHILE Loop In some cases, we wish to repeat a series of commands several times, but only while one or more conditions are satisfied. Like the FOR loop, the WHILE loop allows you to repeat commands, but the WHILE loop provides greater flexibility in specifying the required conditions. The WHILE loop begins with a while statement and ends with a wend statement. Any number of commands may appear between the two statements. WHILE loops can be nested. The WHILE statement consists of the while keyword followed by an expression involving a control variable. The expression should have a logical (true or false) value or a numerical value. In the latter case, zero is considered false and any non-zero value is considered true. If the expression is true, the subsequent statements, up to the matching wend, will be executed, and then the procedure is repeated. If the condition is false,
EViews will skip the following commands and continue on with the rest of the program following the wend statement. For example:
!val = 1
!a = 1
29
Download free eBooks at bookboon.com
29

Introduction to EViews 6.0

Financial Econometrics

while !val dU we do not reject the null hypothesis
The bounds for critical values in the case of negative autocorrelation alternative are 4 − dU and 4 − dL . The values of the bounds can be found in Savin and White
(1977); some of the are tabulated in Table 2.1.
Table 2.1: Lower and Upper bounds for 5% critical values of the Durbin-Watson test Number of regressors k=5 k=7

k=3

n

k=9

dL

dU

dL

dU

dL

dU

dL

dU

25

1.206

1.550

1.038

1.767

0.868

2.012

0.702

2.280

50

1.462

1.628

1.378

1.721

1.291

1.822

1.201

1.930

75

1.571

1.680

1.515

1.739

1.458

1.801

1.399

1.867

100

1.634

1.715

1.592

1.758

1.550

1.803

1.506

1.850

200

1.748

1.789

1.728

1.810

1.707

1.831

1.686

1.852

The Breusch-Godfrey test for autocorrelation considers the regression of the
ˆ
OLS residuals ui upon its lad ui−1 . This auxiliary regression produces an estimate
ˆ
for the first-order autocorrelation coefficient ρ and provides a standard error to this
ˆ
38
Download free eBooks at bookboon.com
38

Regression Model

Financial Econometrics

estimate. In general case the test is easily extended to higher orders of autocorrelation by including additional lags of the residual. Testing the null hypothesis of no autocorrelation is equivalent to testing the significance of the auxiliary regression.
Another common diagnostic for serial correlation is the Ljung-Box modified
Q statistic. The Q-statistic at lag q is a test statistic for the null hypothesis of no autocorrelation up to order q and is computed as: q Q = n(n + 2)

ρ2
ˆj
∼ χ2 , q n−j j=1 where ρj is the j-th autocorrelation.
ˆ
The most often used diagnostic statistic to test for normality of the residuals is the Jarque-Bera test statistics. It measures the difference of the skewness and kurtosis of the series with those from the normal distribution. The statistic is computed as:
(K − 3)2 n S2 +
∼ χ2 ,
JB =
2
6
4
where S is the skewness, and K is the kurtosis. We reject the null hypothesis of normality if a Jarque-Bera statistic exceeds the corresponding critical value.

Brain power

By 2020, wind could provide one-tenth of our planet’s electricity needs. Already today, SKF’s innovative knowhow is crucial to running a large proportion of the world’s wind turbines.
Up to 25 % of the generating costs relate to maintenance. These can be reduced dramatically thanks to our systems for on-line condition monitoring and automatic lubrication. We help make it more economical to create cleaner, cheaper energy out of thin air.
By sharing our experience, expertise, and creativity, industries can boost performance beyond expectations.
Therefore we need the best employees who can meet this challenge!

The Power of Knowledge Engineering

Plug into The Power of Knowledge Engineering.
Visit us at www.skf.com/knowledge

39
Download free eBooks at bookboon.com
39

Click on the ad to read more

Regression Model

Financial Econometrics

2.2.3

Example: Factor Model

Fama and French (1993) suggested a three-factor model to explain the expected stock return premium required by investors. The three factors are
• The excess return of the market portfolio (Rmt ˘rf t );
• The difference between the expected returns on portfolios of small and large firms (SM Bt ); the small and large stock portfolios include all stocks with market capitalization in the lower and upper deciles of the sample median;
• The difference between the expected returns on portfolios of stocks with high and low book-to-market ratios (HM Lt ).
Thus, the expected excess return of stock i can be represented as
Rit − rf t = β0 + β1 (Rit − rf t ) + β2 SM Bt + β3 HM Lt + ut

(2.2.5)

As an example we consider monthly returns on IBM stocks for the period January 1990 to September 2007. This data with Fama-French factors is available as
IBM1.xls. Variables in the data sets are
• ibm – monthly returns on IBM stocks;
• M kt – monthly returns on the market index;
• rf – monthly rate of the risk-free rate;
• SM B and HM L – Fama-French size and book-to-market risk factors, respectively.
In order to estimate the relation (2.2.5) we have to construct excess returns on IBM stocks and market portfolio. In EViews they can be created using series ibm_ex=ibm-rf series Mkt_ex=Mkt-rf
There are two ways of estimating linear regression in EViews. The first one, and more powerful, is through the main menu Quick/Estimate Equation. In the
Equation specification window type the equation to be estimated. Using arithmetic operation we can specify the equation as ibm_ex=C(1)+C(2)*Mkt_ex+C(3)*SMB+C(4)*HML Note that coefficients of the equation should always be in the form C(1), C(2), etc.
However, if the model is linear, it is more common to omit operation and coefficients signs and write
40
Download free eBooks at bookboon.com
40

Regression Model

Financial Econometrics

ibm_ex C Mkt_ex SMB HML
Note, that in the latter specification the dependent variable should be on the first place. The term C indicates that we are estimating the model with intercept; if it is omitted, the regression will be estimated without the intercept term.

Figure 2.1: Regression estimation dialog window

In the Estimated setting window make sure LS – Least Squares (NLS and ARMA) is chosen. The Sample window allows to estimate the model for different subsamples. This option subsample is specified in the same way as in the
Sample object. Press OK and the regression output appears on the screen.
Another way of estimating a linear regression model is through the command line. To create an equation object use the declaration command equation following by a name of the object and the estimation type command (ls in our case stands for least squares) separated by the dot. Finally one should specify the model in the same way as above equation ibmeq.ls ibm_ex C Mkt_ex SMB HML
Estimation Output The regression estimation output looks as follows
The estimated coefficients of the model are given in the column Coefficients
(the coefficient in front of C denote estimate of the intercept term). Slope coefficients denote the sensitivities of the returns on the stock to the three factors and show the impact of systematic factors on returns. In column t-statistic, the value of the test statistic is provided to test that the hypothesis βi = 0. All the coefficients are highly statistically significant as indicated by low p-values (column Prob). The
41
Download free eBooks at bookboon.com
41

Regression Model

Financial Econometrics

Figure 2.2: Regression estimation output

overall significance of the regression is reflected in the value of F-statistic which is high enough to reject the null hypothesis of insignificance of all slope coefficients
(p-value is given in Prob (F-statistic).

42
Download free eBooks at bookboon.com
42

Click on the ad to read more

Regression Model

Financial Econometrics

The proportion of the variance Rit explained by the variability in the market index is the usual regression R2 statistic and 1−R2 is the proportion of the variability of Rit that is due to firm specific factors. The proportion of market specific risk is
R2 = 0.37 and the proportion of firm specific risk is 1 − R2 = 0.63.

By estimating the regression model, EViews produces an object Equation, which can be saved and used later on (press Name button in the top of the equation window). As each object in EViews, Equation can be represented in different views. View/Representation view contains the equation specification of the model, View/Estimation Output provides the familiar model output.
View/Actual, Fitted, Residuals creates various plots of the estimated residual series, as well as fitted values of the dependent variable. Residual series is automatically stored in the series object resid which created by EViews in each workfile.
Note, that resid contains residuals of the last estimated model and will be lost once the model is reestimated. Thus, residual series has to be saved for further use, if necessary. This can done by copying the residual series into a new object series resid_ibm=resid
Now, the residuals from the CAPM regression for IBM stock returns are stored in the new series object resid_ibm.
Besides the standard errors of the coefficient estimators, given in the output window, one can retrieve the whole variance-covariance matrix by clicking on
View/Covariance Matrix.
Residuals Diagnostic Before drawing any conclusions from the estimated regression, it is necessary to perform residual diagnostic to make sure that the assumptions of the classic linear regression model are satisfied. This can be done in the section View/Residual Tests. Correlogram - Q-statistic provides values of the Box-Ljung statistics to test the significance of of autocorrelations of residuals.
The correlogram of the residuals from the factor model is given in Figure ??.
Low p-values indicate absence of serial autocorrelations up to lag 10. Another way to test for series correlation is to perform Breusch-Godfrey Test – in EViews this can be done through Serial Correlation LM Test. In the upper panel of the Breusch-Godfrey test output there are two versions of the test statistic which are asymptotically equivalent. Their p-values both confirm the absence of series autocorrelation up to the second order. The no-autocorrelation null hypothesis is also not rejected by the Durbin-Watson test; test statistic is given in the regression output is equal to 1.959 which is in the acceptance region.
The option Histogram - Normality Test builds the histogram of the residuals, their descriptive statistics as well as the value of the Jarque-Bera statistic.
43
Download free eBooks at bookboon.com
43

Regression Model

Financial Econometrics

Figure 2.3: Correlogram of residuals from the factor model for IBM stock returns

Notice that the Jarque-Bera statistic indicates that the residuals from the CAPM regression are not normally distributed. Note that even the residuals are not normally distributed, the inference is still correct asymptotically.
EViews also provides a number of test to test the hypothesis of homoscedasticity on the regression. Under the option Heteroscedasticity Tests... one can choose among Breush-Godfrey-Pagan, Harvey, Glejser, ARCH and White tests.
Three of them – Breush-Godfrey-Pagan, Glejser and White tests reject the hypothesis of homoscedasticity while Harvey and ARCH test do not reject the null.
The reason for using several tests is that there are many different possible alternatives for the form of heteroscedasticity.
All the tests for autocorrelations and heteroscedasticity can be performed through the command line as well.
For the Breusch-Godfrey test for serial correlation we should specify the name of the regression equation we need to test and then the command auto(lags) where lags corresponds to the order of autocorrelation being tested. For example ibm_eq.auto(2) will perform the test for second order autocorrelation in the factor model for IBM stock. To perform heteroscedasticity tests we should specify the equation name followed by the command hettest(options). In the options field we can specify the test being performed in the following way: type=keyword, where keyword is either "BPG"
44
Download free eBooks at bookboon.com
44

Regression Model

Financial Econometrics

(Breusch-Pagan-Godfrey - default), "Harvey", "Glejser", "ARCH", or "White". Inclusion of the command c in the options will lead to inclusion of cross-product terms in the auxiliary regression specification. Optionally, a list of variables may follow the command to include them into auxiliary regression as well.
For example, ibm_eq.hettest(type="White",c) will perform the WHite’s test for heteroscedasticity for the ibm_eq equation.
Since the exact form of heteroscedasticity is not known, it is not clear how to perform GLS estimator is this case. EViews allows to compute heteroskedasticity consistent as well as heteroskedasticity and autocorrelation consistent coefficient covariance matrices. In order to compute them, click on Estimate button in the object menu and choose the Options tab. Tick the box in front of Heteroscedasticity consistent coefficient matrix to activate the option. Click OK to reestimate the model. Figure 2.4: Regression output with White’s heteroscedasticity adjusted standard errors All coefficients remain still statistically significant using White’s heteroscedasticity consistent standard errors.
Stability tests Finally, we can test the model for coefficients stability and structural breaks. In EViews this can be performed under the option Views/Stability tests. With Ramsey RESET test for model misspecification we cannot reject the null hypothesis of the correct specification (p-value 0.3754).
We start stability tests with the recursive residuals tests as they can help
45
Download free eBooks at bookboon.com
45

Regression Model

Financial Econometrics

us to detect visually potential breakpoints. Click on Recursive Estimates (OLS only) and choose Recursive residuals. EViews will produce the plot of recursively estimated residuals from the model together with their confidence intervals.

Figure 2.5: Recursively estimated residuals and their confidence bounds

46
Download free eBooks at bookboon.com
46

Click on the ad to read more

Regression Model

Financial Econometrics

Majority of the recursive residuals are within their confidence intervals however there are several outliers spraying out their bounds. These are potential points for the structural breaks in the models. The CUSUM test does not indicate any potential breakpoints, however the CUSUM squared test suggests that there may be some breaks in sixties and at the beginning of 2000.

Figure 2.6: CUSUM squared statistics and its confidence bounds

We can go further and test whether there is a structural break at the specified dates using the Chow test. The p-value of the F-statistic for the Chow test is
0.3090 at the breakpoint January 1961 indicating no structural break at that date.
However, if the breakpoint is specified at January 2000, we reject the null hypothesis of the parameters constancy at 1% significance level. Structural breaks may occur in the model due to some misspecifications. For example, from January 2000 there is one missing factor in the model which plays important role in explaining stock returns. The breakpoint data also corresponds to the dot.com bubble period where the classic factors model structure may change. In order to verify our hypothesis, we can include dummy variable corresponding to the bubble period to eliminate the effect from the model. To create the dummy which is equal to 1 for the period from
January 2000 to December 2001, we write series dummy=0 smpl 2000M01 2001M12 series dummy=1
47
Download free eBooks at bookboon.com
47

Regression Model

Financial Econometrics

smpl @all
Since structural breaks may occur in all the parameters, we include the dummy variable interacting with all regressors. Thus, in the Estimate equation box we have to specify a new model ibm_ex C Mkt_ex SMB HML dummy*Mkt_ex dummy*SMB dummy*HML
As a result, the coefficient for interacting term with market portfolio returns and
SMB factor is insignificant, however the interacting term with HML factor is statically significant at 10% level.

Figure 2.7: Output of the regression estimation with dummy variables

Correcting of misspecification also helps to improve properties of residuals.
After introducing dummy variable all tests for heteroscedasticity indicate either no heteroscedasticity or produce some marginally significant p-values.
Testing linear restrictions EViews makes it possible to test hypothesis on the coefficient restrictions by means of Wald test. Consider testing the joint null hypothesis β1 = 1 and β2 = β3 . This hypothesis imposes two linear restrictions on the parameter vector. In the View option of the object menu choose Coefficient
Tests/Wald – Coefficient Restrictions.... Type the restrictions to be tested in the box. Note that coefficients of the model are denoted by C(1), C(2), etc. In order to find out the exact notations of the parameters, go to View/Representation.
P-value of the Wald test statistic is higher than any reasonable significance levels so we do not reject the null hypothesis of the validity of the restrictions.
48
Download free eBooks at bookboon.com
48

Regression Model

Financial Econometrics

The Wald test can also be performed in the command line. One should first specify the name of equation being tested followed by dot and command wald. Specifications of the restrictions follows separated by commas. eq1.wald c(2)=0, c(3)=0
Predictions After having estimated the regression, often our aim is to construct forecast of the dependent variable. EViews’ forecast function can be invoked through Forecast option in the menu of the equation object. In the box Forecast name type the name of the variable where the regression forecasts will be stored.
EViews will automatically create a new series object with the specified name and plot the predicted series with two confidence region bounds.
Alternatively, one can view the forecast by double-click on the forecast variable.
In the menu option View choose Graph where the required graph type can be generated. In order to generate forecasts through the command line, use the command fit followed by a name of a series variable where the forecast values should be stored ibmeq.fit ibm_exf

Challenge the way we run

EXPERIENCE THE POWER OF
FULL ENGAGEMENT…
RUN FASTER.
RUN LONGER..
RUN EASIER…

READ MORE & PRE-ORDER TODAY
WWW.GAITEYE.COM

49
Download free eBooks at bookboon.com
1349906_A6_4+0.indd 1

22-08-2014 12:56:57

49

Click on the ad to read more

Regression Model

Financial Econometrics

EViews also allows to generate standard errors of the forecasts along with the predictions themselves. To do this, simply include a name of another variable at the end of the line. ibmeq.fit ibm_exf ibm_exfstd

2.2.4

Programming Example

Note that the factor sensitivities of stock (portfolio) returns represented by the estimated coefficients vary through time. As the model is estimated for alternative sample periods, the estimated coefficients will change. A useful analogy is the value of a stock’s beta that varies through time based on the sample period data used to estimate the security market line.
The estimated factor model (2.2.5) for IBM uses all of the data over the 57 year period from January 1950 to September 2007. It is generally thought that coefficients do not stay constant over such a long time period. To take into account this fact while building returns forecast based on the factor model, we can perform rolling window regression. We start with initializing necessary variables (e.g., number of observation in the workfile, length of the window). For this purpose we make sure that the current sample is set to the whole range of the data. Type the following commands in a new program window: smpl @all scalar n=@obs(ibm_ex) scalar window=60
Next, we create new object we will be using in the program – series of the forecasts and an equation object. series ibm_exf equation e
In the next lines we specify a loop where we reset the current sample to the estimation window and roll it across the data range. For each of the subsamples we estimate the factor model. for !i=0 to n-window-1 smpl @first+!i @first+!i+window-1
e.ls ibm_ex c Mkt_ex SMB HML
Once the model is estimated we reset the sample to a subsample where we want
50
Download free eBooks at bookboon.com
50

Regression Model

Financial Econometrics

to forecast returns. Since we build one-step-ahead forecast, our new subsample will be just one observation ahead the estimation window. smpl @first+!i+window @first+!i+window
We generate the forecast using the estimated model. To access the values of the estimated parameters we use EViews function @coefs. In parentheses we specify the order of the parameter – it corresponds to the order of respective variable in the regression model. Note that @coefs contains the values of the last estimated model.
Once the equation is re-estimated, the new values of parameters are stored in @coefs. ibm_exf=@coefs(1)+@coefs(2)*Mkt_ex+@coefs(3)*smb+@coefs(4)*hml next
Just to tidy up the workfile we delete auxiliary variables window and n. delete window n
The series ibm_exf contains the generated forecast from the rolling window model.
Similarly to the use of @coefs function, one can access other OLS statistics.
The specifications are given in Table 2.2.

51
Download free eBooks at bookboon.com
51

Click on the ad to read more

Regression Model

Financial Econometrics

Table 2.2: Equation Data Members
Data Member

Description

@aic

Akaike information criterion

@coefcov(i,j)

covariance of coefficient estimates βi and βj

@coefs(i)

i-th coefficient value

@dw

Durbin-Watson statistic

@f

F-statistic

@hq

Hannan-Quinn information criterion

@logl

value of the log likelihood function

@meandep

mean of the dependent variable

@ncoef

number of estimated coefficients

@r2

R-squared statistic

@rbar2

adjusted R-squared statistic

@regobs

number of observations in regression

@schwarz

Schwarz information criterion

@sddep

standard deviation of the dependent variable

@se

standard error of the regression

@ssr

sum of squared residuals

@stderrs(i)

standard error for coefficient

@tstats(i)

t-statistic value for coefficient

@coefcov

matrix containing the coefficient covariance matrix

@coefs

vector of coefficient values

@stderrs

vector of standard errors for the coefficients

@tstats

vector of t-statistic values for coefficients

2.3

Nonlinear Regression

In many cases the relation between variables can happen to be nonlinear. If such model cannot be transformed into a linear one, we call such model intrinsically nonlinear regression model.
We can represent such model in the following way bf Y = F (X, θ) + u, where F is a non-linear function, where Xi = [1, X2i , ..., Xki ] is a k × 1 vector of explanatory variables, and ui is a random error term.
The least squares estimation problem to minimize n S(θ) = i−1 (Yi − F (Xi , θ)2

becomes non-linear. The first order conditions are given by n ∂S(θ)
∂F
= −2
(Yi − F (Xi , θ))
.
∂θj
∂θj
i−1
52
Download free eBooks at bookboon.com
52

(2.3.1)

Regression Model

Financial Econometrics

This gives a set of non-linear normal equations in θ. The non-linear least squares
ˆ
(NLS) estimator θN LS is defined as the minimizing value of (2.3.1).
In EViews, the Nonlinear Least Squares method has the same implementation as the OLS. The only difference os that the model in the Equation specification box should be entered as a mathematical expression instead of a list of variables. for example, y=@exp(c(1)*x)+(c(2)*z+4)∧ 2
Interpretation of the estimation output, residual diagnostic and inference can be performed in the same way as for the OLS regression.

www.sylvania.com

We do not reinvent the wheel we reinvent light. Fascinating lighting offers an infinite spectrum of possibilities: Innovative technologies and new markets provide both opportunities and challenges.
An environment in which your expertise is in high demand. Enjoy the supportive working atmosphere within our global group and benefit from international career paths. Implement sustainable ideas in close cooperation with other specialists and contribute to influencing our future. Come and join us in reinventing light every day.

Light is OSRAM

53
Download free eBooks at bookboon.com
53

Click on the ad to read more

Univariate Time Series: Linear Models

Financial Econometrics

Chapter 3
Univariate Time Series: Linear
Models
3.1

Introduction

Time series is a sequence of numerical data in which observations are measured at a particular instant of time. The frequency of observation can, for example, be annual, quarterly, monthly, daily, etc. The main goal of time series analysis is to study the dynamics of the data.
In this chapter we introduce basic time series models for estimation and forecasting of financial data. Further details about theory of time series analysis cab be found in Hamilton (1994), Greene (2000), Enders (2004), Tsay (2002) and others.

3.2
3.2.1

Stationarity and Autocorrelations
Stationarity

A time series {Yt } is said to be strictly stationaryif for all integers i, j and all possible integers k the multivariate distribution function of (Yi , Yi+1 , ..., Yi+k−1 ) is identical to (Yj , Yj+1 , ..., Yj+k−1 ). In practice we are very often interested in consequences of this assumption regarding moments of the distribution. If Yi and Yj have identical distribution this implies that their means are identical, thus E[Yt ] does not depend on time and equal to some constant µ. Also, because the pairs (Yi , Yi+s ) and (Yj , Yj+s ) have identical bivariate distributions it follows that the autocovariances cov(Yt , Yt+s ) = E [(Yt − µ)(Yt+s − µ)] = λs

depend only on the time lag s. This implies also that Yt have constant variance λ0 = σ 2 .
54

Download free eBooks at bookboon.com
54

Univariate Time Series: Linear Models

Financial Econometrics

A stochastic process whose first and second order moments (means, variances, and covariances) do not change with time is said to be second order stationary. More precisely, a time series Yt is called stationary if the following conditions are satisfied:
E[Yt ] = µ, E[(Yt − µ)2 ] = γ0 , E[(Yt − µ)(Yt−s − µ)] = γs for all t
Here µ, γ0 , and γk are finite-valued numbers that do not depend on time t.

3.2.2

Autocorrelation

γs
The autocorrelations of a stationary process are defined by ρs = γ0 . These correlations describe the short-run dynamic relations within the time series, in contrast with the trend, which corresponds to the long-run behaviour of the time series.
The simplest possible autocorrelations occur when a stationary process consists of uncorrelated random variables. In this case ρ0 = 1, ρs = 0 for all s > 0. Such time series is called white noise.
It is important when modeling financial returns to appreciate that if {Yt } is white noise then Yt and Yt+s are not necessarily independent for s > 0.
The partial autocorrelation φs at lag s measures the correlation of Yt values that are s periods apart after removing the correlation from the intervening lags. It equals the regression coefficient on Yt−s when Yt is regressed on a constant, Yt−1 ,...,
Yt−s .
Time series prediction To describe the correlations, we imagine that our observed time series comes from a stationary process that existed before we started observing it. We denote the past of the stationary process Yt by Yt−1 = {Yt−1 , Yt−1 , ...}, where the "dots" mean that there is no clear-cut beginning of this past. We call it also the information set available at time point t − 1. The least squares predictor of
Yt based on the past Yt−1 is the function f (Yt−1 ) that minimizes E [(Yt − f (Yt−1 ))2 ].
This predictor is given by the conditional mean f (Yt−1 ) = E[Yt |Yt−1 ] with corresponding (one-step-ahead) prediction errors et = Yt − f (Yt−1 ) = Yt − E[Yt |Yt−1 ].
The process et is also called the innovation process, as it corresponds to the unpredictable movements in Yt . If the observations are jointly normally distributed, then the conditional mean is a linear function of the past observations

E[Yt |Yt−1 ] = a + p1 Yt−1 + p2 Yt−2 + ...
Here a models the mean E[Yt ] = µ of the series. From the above equation we get µ = a + pk µ, so that µ = (1 − pk )−1 . As the process is assumed to be stationary, the coefficients pk do not depend on time and the innovation process et is also stationary. It has the following properties:
55
Download free eBooks at bookboon.com
55

Univariate Time Series: Linear Models

Financial Econometrics

• E[et ] = 0 for all t
• E [e2 ] = σ 2 for all t; t • E[es et ] = 0 for all s = t.
Here the variance σ 2 is constant over time.

3.2.3

Example: Variance Ratio Test

Very often a predictability of stock returns is linked to the presence of autocorrelation in the returns series. If stock returns form an iid process, then variances of holding period returns should increase in proportion to the length of the holding period.
If the log return is constant, then under the rational expectation hypothesis stock prices follows a random walk

360° thinking .

h

pt+h = µ + pt+h−1 + ut+h = µ + µ + pt+h−2 + ut+h + ut+h−1 = pt + µh +

360° thinking .

ut+i . i=0 360° thinking .

Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Discover the truth at www.deloitte.ca/careers
56

© Deloitte & Touche LLP and affiliated entities.

Download free eBooks at bookboon.com
56
Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Click on the ad to read more

© Deloitte & Touche LLP and affiliated entities.

D

Univariate Time Series: Linear Models

Financial Econometrics

Variance of the returns forecasts h var [pt+h − pt ] =

E u2 = hσ 2 t+i i=0

due to the independence. Alternatively, if log returns are iid, then var [rt,t+h ] = var [rt,t+1 + rt+1,t+2 + ... + rt+h−1,t+h ] = hvar [rt+1 ]
The variance-ratio statistic is defined as h−1 2
1 var [rt,t+k ]
V Rh =
=1+
(h − j)ρj , h var [rt+1 ] h j=1 which should be unity if returns are iid and less than unity under mean reversion.
The variance ratio test is set up as H0 : V Rh = 1 and under the null
Zh =

V Rh − 1

2(2h − 1)(h − 1)/3hT

∼ N (0, 1).

See Cuthbertson and Nitzsche (2004) for more details about the test. Let us consider as an example how to program the variance ratio test in EViews.
In this test uses overlapping h-period returns. As an input to the program, the workfile should contain a series of log prices p used to test for predictability. We start the program in a usual way. smpl @all
!h=2
The variable !h denotes the horizon of the returns forecast. The next we create one period and h period returns. smpl @first+1 @last series r=p-p(-1)
In order to build the variance ratio statistics we need to have the actual number of observations (returns), mean and variance of returns series. scalar T=@obs(p) scalar mu=@mean(r) scalar var1=@sumsq(r-mu)/(T-1) smpl @first+!h @last series rh=p-p(-!h)
57
Download free eBooks at bookboon.com
57

Univariate Time Series: Linear Models

Financial Econometrics

scalar varh=@sumsq(rq-!h*mu)/(T-!h+1)
We can now compute the variance ratio statistic scalar VRh=varh/(!h*var1) scalar Zh=(VRh-1)/@sqrt((2*(2*!q-1)*(!q-1))/(3*!q*T))
We need a p-value in order to test the hypothesis. Two-sided significance level
(p-value) can be calculated as a follows scalar Zh_level=2*(1-@cnorm(@abs(Zh)))
Finally, we create a table to report the results. We declare a new table VRTEST object with 2 rows and 5 columns, set the width of each column and write the context of each sell down. table(2,5) VRTEST
Setcolwidth(VRTEST,1,15)
Setcolwidth(VRTEST,2,15)
Setcolwidth(VRTEST,3,10)
Setcolwidth(VRTEST,4,10)
Setcolwidth(VRTEST,5,13)
Setcell(VRTEST,1,1,"Nr of obs")
Setcell(VRTEST,1,2,"Horizon h")
Setcell(VRTEST,1,3,"VRh")
Setcell(VRTEST,1,4,"test stat Zh")
Setcell(VRTEST,1,5,"p-value")
Setcell(VRTEST,2,1,T,0)
Setcell(VRTEST,2,2,!h,0)
Setcell(VRTEST,2,3,VRh,4)
Setcell(VRTEST,2,4,Zh,4)
Setcell(VRTEST,2,5,Zh_level,5) delete r mu rh T var1 varh Zh Zh_level next 58
Download free eBooks at bookboon.com
58

Univariate Time Series: Linear Models

Financial Econometrics

3.3

ARMA processes

A zero mean white noise process {εt } can be used to construct new processes. We describe two commonly used examples first and afterwards their generalization – autoregressive-moving average (ARMA) model.

3.3.1

Autoregressive process

A simple way to model dependence between consecutive observations is
Yt = α0 + α1 Yt−1 + εt , where εt is white noise.Such process is called a first-order autoregressive process or
AR(1) process. It is stationary if the coefficient |α1 | < 1.
Since E[εt ] = 0 it follows that under the stationarity condition the mean of the
2
σε α0 2 process E[Yt ] = 1−α1 and variance var[Yy ] = 1−α2 where σε = var[εt ]. An AR(1)
1
s process has autocorrelations ρs = α1 for s > 1.
A more general representation of the autoregressive process is
Yt = α0 + α1 Yt−1 + ... + αp Yt−p + εt and called an autoregressive process of order p, or in short, AR(p).

59
Download free eBooks at bookboon.com
59

Univariate Time Series: Linear Models

Financial Econometrics

3.3.2

Moving average process

Consider the process {Yt } defined by
Yt = α0 + εt + β1 εt−1 so Yt is a linear function of the present and immediately preceding innovations. This process is called a moving average process of order 1 and denoted by M A(1).
2
2
A M A(1) process is always stationary with mean α0 and variance (1 + β1 ) σε . β1 Its autocorrelations are ρ1 = 1+β 2 and ρs = 0 for s > 1.
1
Comparing two time series we see that a shock εt in M A(1) process affects Yt in two periods (only two positive autocorrelation coefficients), while a shock in the
AR(1) process affects all future observations with a decreasing effect.
The M A(1) process may be inverted to give εt as an infinite series in Yt , Yt−1 ,..., namely 2 εt = Yt + β1 Yt−1 + β1 Yt−2 + ... that is
2
Yt = −β1 Yt−1 − β1 Yt−2 − ... + εt .

Thus, M A(1) time series can be represented as AR(∞) process. It is possible to invert M A(1) process into a stationary AR process only if |β1 | < 1. This condition is known as invertibility condition.
A more general representation of a moving average process is
Yt = α0 + εt + β1 εt−1 + ... + βq εt−q and called a moving average process of order q, or in short, M A(q).

3.3.3

ARMA process

It is possible to combine the autoregressive and moving average specification into
ARM A(p, q) model
Yt = α1 Yt−1 + ... + αp Yt−p + εt + β1 εt−1 + ... + βq εt−q .

(3.3.1)

An ARM A(p, q) time series can be represented in a shorter form using the notion of lag operator.
The lag operator L, is defined as LYt = Yt−1 , the operator which gives the previous value of the series. This operator can also be used to represent the lags of the second or higher orders in the following way:
L2 (Yt ) = L(L(Yt )) = L(Yt−1 ) = Yt−2 .
60
Download free eBooks at bookboon.com
60

Univariate Time Series: Linear Models

Financial Econometrics

In general ARM A(p, q) process is
A(L)Yt = B(L)εt , where A(L) = 1 − α1 L − α2 L2 − ... − αp Lp
B(L) = 1 − β1 L − β2 L2 − ... − βq Lq
Stationarity requires the roots of A(L) to lie outside the unit circle, and invertibility places the same condition on the roots of B(L).
Table 3.1: Correlation patterns

Time series
AR(p)
M A(q)
ARM A(p, q)

3.3.4

acf
Infinite: decays towards zero
Finite: disappears after lag q
Infinite: damps out

pacf
Finite: disappears after lag p
Infinite: decays towards zero
Infinite: decays towards zero

Estimation of ARMA processes

ARM A(p, q) models are generally estimated using the technique of maximum likelihood.
An often ignored aspect of the maximum likelihood estimation of ARM A(p, q) models is the treatment of initial values. These initial values are the first p values of Yt and q values of εt in (3.3.1). The exact likelihood utilizes the stationary distribution of the initial values in the construction of the likelihood. The conditional likelihood treats the p initial values of Yt as fixed and often sets the q initial values of εt to zero. The exact maximum likelihood estimates (MLE) maximize the exact loglikelihood, and the conditional MLE maximize the conditional log-likelihood. The exact and conditional MLEs are asymptotically equivalent but can differ substantially in small samples, especially for models that are close to being non-stationary or non-invertible.
For pure AR models, the conditional MLEs are equivalent to the least squares estimates Model Selection Criteria Before an ARM A(p, q) may be estimated for a time series Yt , the AR and M A orders p and q must be determined by visually inspecting the autocorrelation and partial autocorrelation functions for Yt . If the autocorrelation function decays smoothly and the partial autocorrelations are zero after one lag, then a first-order autoregressive model is appropriate. Alternatively,
61
Download free eBooks at bookboon.com
61

Univariate Time Series: Linear Models

Financial Econometrics

if the autocorrelations were zero after one lag and the partial autocorrelations decay slowly towards zero, a first-order moving average process would seem appropriate.
Alternatively, statistical model selection criteria may be used. The idea is to fit all ARM A(p, q) models with orders p and q and choose the values of p and q which minimizes model selection criteria:
AIC(p, q) = ln σ 2 (p, q) +
˜

2
(p + q)
T

ln(T )
(p + q)
T
where σ 2 (p, q) is the MLE of var[εt ] = σ 2 without a degrees of freedom correction
˜
from the ARM A(p, q) model.
BIC(p, q) = ln σ 2 (p, q) +
˜

3.3.5

Example: ARMA in EViews

We start our example from the simulation of ARMA process and then we take a look at its estimation. In order to illustrate the statements in Table 3.1, let us simulate
AR(3), M A(2) and ARM A(3, 2) processes and compute their autocorrelation and partial autocorrelation functions.

We will turn your CV into an opportunity of a lifetime

Do you like cars? Would you like to be a part of a successful brand?
We will appreciate and reward both your enthusiasm and talent.
Send us your CV. You will be surprised where it can take you.

Send us your CV on www.employerforlife.com 62

Download free eBooks at bookboon.com
62

Click on the ad to read more

Univariate Time Series: Linear Models

Financial Econometrics

In particular, we simulate
Yt = 0.8Yt−1 + 0.15Yt−2 − 0.1Yt−3 + ut
Yt = ut − 0.95ut−1 + 0.3ut−2

(3.3.2)

Yt = 0.8Yt−1 + 0.15Yt−2 − 0.1Yt−3 + ut − 0.95ut−1 + 0.3ut−2

To start with, we generate a series of uncorrelated normally distributed residuals (remember, command nrnd generates standard normally distributed random number) series u=0.5*nrnd
Also, we have to generate initial values for the series. Since the highest order of the series is 3, let us generate first three values. This can be done by setting sample to only fist three observations and assign zero values to all of three series. smpl @first @first+2 series y1=0 series y2=0 series y3=0
Now, we set the sample for the rest of observations and generate series according to formulae (3.3.2) smpl @first+3 @last y1=0.8*y1(-1)+0.15*y1(-2)-0.1*y1(-3)+u y2=u-0.95*u(-1)+0.3*u(-2) y3=0.8*y1(-1)+0.15*y1(-2)-0.1*y1(-3)+u-0.95*u(-1)+0.3*u(-2) Now, we are ready to build and inspect their correlograms. Remind, that in order to build a correlogram, one should click on the icon if the time series being investigated and choose View/Correlogram... option. The correlograms of three time series is given on Figures ??-??.
As we have expected, the autocorrelation function for the first series (AR(3)) damps out slowly towards zero while its partial autocorrelation function has spikes at first three lags. The autocorrelation function of the second series (M A(2)) has spikes at two first lags and disappears afterwards (becomes insignificant) while the partial autocorrelation function decays oscillating towards zero. Both autocorrelation and partial autocorrelation functions of the third series (ARM A(3, 2)) decay slowly towards zero without any clear spikes.
63
Download free eBooks at bookboon.com
63

Univariate Time Series: Linear Models

Financial Econometrics

Figure 3.1: Correlogram of an AR(3) process

Figure 3.2: Correlogram of a M A(2) process

Estimation An estimation of the ARMA processes is performed in EViews in the same way as OLS estimation of a linear regression. The only difference is in specifying autoregressive and moving average terms in the model. If the series has got autoregressive components, we should include terms ar(1), ar(2), etc, as regressors up to the required order. For example, to estimate the first series, type y1 c ar(1) ar(2) ar(3) in the estimation equation box. EViews produces an output given in Figure ??
All coefficients are significant as expected and are very close to the true values.
64
Download free eBooks at bookboon.com
64

Univariate Time Series: Linear Models

Financial Econometrics

Figure 3.3: Correlogram of an ARM A(3, 2) process

Figure 3.4: Estimation output of ARM A process

Inference and tests can be performed in the same way as it was done for the OLS regression. If one needs to estimate the model containing moving average components, ma(1), mar(2), etc terms should be included into the model specification. For example, to estimate the second time series, we write y2 c ma(1) ma(2)
Autoregressive and moving average terms can be combined to estimate ARMA
65
Download free eBooks at bookboon.com
65

Univariate Time Series: Linear Models

Financial Econometrics

model. Thus, specification of the third series looks like y3 c ar(1) ar(2) ar(3) ma(1) ma(2)
After having estimated an ARMA model, one can check whether the estimated coefficients satisfy the stationarity assumptions. This can be done through View/ARMA structure of the Equation object. For the third series we obtain

Figure 3.5: Table of the roots of the estimated ARM A process

It says that our ARMA series is both stationary and invertible.

3.3.6

Programming example

If we had not known the order of the ARMA series, we would need to apply one of the information criteria to select the most appropriate order of the series. The following program illustrates how this can be done using the Akaike criterion.
First we need to define the maximal orders for autoregressive and moving average parts and store them into variables pmax and qmax. Also we need to declare a matrix object aic where the values of the Akaike statistic will be written for each specification of the ARMA process. smpl @all scalar pmax=3 scalar qmax=3 matrix(pmax+1,qmax+1) aic
66
Download free eBooks at bookboon.com
66

Univariate Time Series: Linear Models

Financial Econometrics

Next, we define nested loops which will run through all possible ARMA specification with orders within the maximal values. for !p=0 to pmax for !q=0 to qmax
As the number of lags included in the model increases we add a new AR term in the model. For this purpose we create a new string variable textsf%order containing the model specification. if !p=0 then %order="" else for !i=1 to !p
%order=%order+" ar("+@str(!i)+")" next endif

I joined MITAS because
I wanted real responsibili�
I joined MITAS because
I wanted real responsibili�

Real work
International
Internationa opportunities al �ree wo placements work or

67

�e Graduate Programme for Engineers and Geoscientists

Maersk.com/Mitas www.discovermitas.com M

Month 16
I was a construction
M
supervisor ina cons
I was the North Sea super advising and the No he helping foremen advis s Real work solve problems he helping f
International
Internationa opportunities al �ree wo placements work or s solve p

Download free eBooks at bookboon.com
67

�e for Engin

Click on the ad to read more

Univariate Time Series: Linear Models

Financial Econometrics

We perform the same procedure with the MA term specification. if !q=0 then %order=%order+"" else for !i=1 to !q
%order=%order+" ma("+@str(!i)+")" next endif
Once the model specification is determined and written in the variable %order we can use a substitution to estimate the corresponding model. equation e.ls y3 c %order
%order=""
The last command nullify the variable %order for the use in the next step of the loops. Now we can write the value of the Akaike criterion for the current in the table. aic(!p+1,!q+1)=e.@aic next next delete e
After the program run, the values of the Akaike criterion are stored in the table aic. Now we can choose that specification of the ARMA model which produces the smallest AIC value.

68
Download free eBooks at bookboon.com
68

Stationarity and Unit Roots Tests

Financial Econometrics

Chapter 4
Stationarity and Unit Roots Tests
4.1

Introduction

Many financial time series, like exchange rate levels of stock prices appear to be non-stationary. New statistical issues arises when analyzing non-stationary data.
Unit root tests are used to detect the presence and form of non-stationarity.
This chapter reviews main concepts of non-stationarity of time series and provides a description of some tests for time series stationarity. More information about such tests can be found in Hamilton (1994), Fuller (1996), Enders (2004),
Harris (1995), Verbeek (2008).
There are two principal methods of detecting nonstationarity:
• Visual inspection of the time series graph and its correlogram;
• Formal statistical tests of unit roots.
We will start with formal testing procedures first.
A nonstationaty time series is called integrated if it can be transformed by first differencing once or a very few times into a stationary process. The order of integration is the minimum number of of times the series needs to be first differenced to yield a stationary series. An integrated of order 1 time series is denoted by I(1).
A stationary time series is said to be integrated of order zero, I(0).

4.2

Unit Roots tests

Let us consider a time series Yt in the form
Yt = α + βYt−1 + ut ut = ρut−1 + εt
69

Download free eBooks at bookboon.com
69

(4.2.1)

Stationarity and Unit Roots Tests

Financial Econometrics

Unit root tests are based on testing the null hypothesis that H0 : ρ = 1 against the alternative H1 : ρ < 1. They are called unit root tests because under the null hypothesis the characteristic polynomial has a root equal to unity. On the other hand, stationarity tests take the null hypothesis that Yt is trend stationary.

4.2.1

Dickey-Fuller test

One commonly used test for unit roots is the Dickey-Fuller test. In its simplest form it considers a AR(1) process
Yt = ρYt−1 + ut where ut is an IID sequence of random variables. We want to test
H0 : ρ = 1 vs. H1 : ρ < 1.
Under the null hypothesis Yt is non-stationary (random walk without drift). Under the alternative hypothesis, Yt is a stationary AR(1) process.
Due to non-stationarity of Yt under the null, the standard t-statistic does not follow t distribution, not even asymptotically. To test the null hypothesis, it is possible to use ρ−1 ˆ
.
DF =
s.e (ˆ) ρ Critical values, however, have to be taken from the appropriate distribution, which is under the null hypothesis of non-stationarity is nonstandard. The asymptotic critical values of DF based on computer simulations are given in Fuller (1996).
The above test is based on the assumption that the error terms are iid and there is no drift (intercept term) in the model. The limiting distribution will be wrong if these assumptions are false.
More general form of the Dickey-Fuller test employs other variants of the time series process. Consider the following three models for the data generating process of Yt :
Yt = ρYt−1 + ut

(4.2.2)

Yt = ρYt−1 + α + ut

(4.2.3)

Yt = ρYt−1 + α + βt + ut

(4.2.4)

with ut being iid process.
Dickey and Fuller (1979) derive a limiting distribution for the least squares t-statistic for the null hypothesis that ρ = 1 and F-statistic (Wald statistic) for the null hypotheses of validity of combinations of linear restrictions ρ = 0, α = 0 and β = 0 where the estimated models are from (4.2.2) to (4.2.4) but in each case that
(4.2.2) is the true data generating process.
70
Download free eBooks at bookboon.com
70

Stationarity and Unit Roots Tests

Financial Econometrics

4.2.2

Augmented Dickey-Fuller test

Dickey and Fuller (1981) show that the limiting distributions and critical values that they obtain under the assumption of iid ut process are also valid when ut is autoregressive, when augmented Dickey-Fuller (ADF) regression is run. Assume the data are generated according to (4.2.2) with ρ = 1 and that
(4.2.5)

ut = θ1 ut−1 + θ2 ut−2 + ... + θp ut−p + εt where εt are iid. Consider the regression
∆Yt = φYt−1 + α + βt + ut

and test H0 : φ = 0 versus H1 : φ < 0. Given the equation for ut in (4.2.5) we can write ∆Yt = φYt−1 + α + βt + θ1 ut−1 + θ2 ut−2 + ... + θp ut−p + εt .
Since under ρ = 1 we have ut = Yt − Yt−1 , this equation can be rewritten as
∆Yt = φYt−1 + α + βt + θ1 ∆Yt−1 + θ2 ∆Yt−2 + ... + θp ∆t−p + εt .

(4.2.6)

Said and Dickey (1984) provide a generalization of this result for ARM A(p, q) error terms. 71
Download free eBooks at bookboon.com
71

Click on the ad to read more

Stationarity and Unit Roots Tests

Financial Econometrics

Procedure Before using the ADF test we have to decide how many lags of
∆Y to include in the regression. This can be done by sequentially adding lags and testing for serial correlation using Lagrange multiplier tests to archive a white noise residuals. Use F-test to test the null (β, ρ) = (0, 1) against the alternative (β, ρ) = (0, 1).
If the null is rejected we know that either β=0 ρ=1 β=0 ρ=1 or

or

β=0 ρ=1 and the next step is to test ρ = 1 using the t-statistic obtained from the estimating the augmented version of (4.2.4), with the critical values taken from the standard normal tables. Critical values from the standard normal are appropriate when β is non-zero, so that if the null hypothesis is not rejected we can rule out the second and third cases (if β is zero the critical values are non-standard, but will be smaller than the standard normal ones). Thus, if ρ = 1 is accepted we conclude that β = 0 and ρ = 1, so that series has a unit root and a linear trend.
If we reject the null then the first alternative can be dismissed. This leaves the following two alternatives either β=0 ρ=1 or

β=0 ρ=1 In either case ρ is not 1, there is no unit root and conventional test procedures can be used. Thus we may carry out a t test for the null that β = 0.
If we cannot reject (β, ρ) = (0, 1) we know that the series has a unit root with no trend but with possible drift. To support the conclusion that ρ = 1 we may test this, given β is assumed to be zero.
If we wish to establish whether the series has non-zero drift, further tests will be required. Note that we know (β, ρ) = (0, 1), and so we might carry out the F test. This tests
H0 : (α, β, ρ) = (0, 0, 1) vs. (α, β, ρ) = (0, 0, 1).
If we cannot reject the null hypothesis, the series is random walk without drift. If we reject it, the series is a random walk with drift.
We may wish to support these findings on the basis of estimating (4.2.3) by setting β at zero as suggested by the various previous tests. If β is actually zero then tests on α and ρ should have greater power once this this restriction is imposed.
72
Download free eBooks at bookboon.com
72

Stationarity and Unit Roots Tests

Financial Econometrics

4.2.3

Phillips and Perron tests

The statistics proposed by Phillips and Perron (1988) (Z statistics) arise from their considerations of the limiting distributions of the various Dickey-Fuller statistics when the assumption that ut is an iid process is relaxed.
The test regression in the Phillips-Perron test is
∆Yt = φYt−1 + α + βt + ut where ut is a stationary process (which also may be heteroscedastic). The PP tests correct for any serial correlation and heteroscedasticity in the errors ut of the test regression by directly modifying the test statistics. These modified statistics, denoted Zt and Zφ , are given by
Zt =

1
2

σ2
ˆ
ˆ λ2 Zφ = T φ −

1
2

ˆ
ˆ
λ2 − σ 2
ˆ
λ2

1
2

tφ=0 −

ρ
T 2 s.e (ˆ)
2
σ
ˆ

T s.e (ˆ) ρ 2 σ ˆ
ˆ
λ2 − σ 2
ˆ

ˆ
The terms σ 2 and λ2 are consistent estimates of the variance parameters
ˆ
T
2

σ = lim T
ˆ
T →∞

−1

E u2 t t=1

T

ˆ λ2 = lim

T →∞

where ST =

T

2
E T −1 ST t=1 ut .

t=1

In the Dickey-Fuller specification we can use the critical values given by Dickey and Fuller for the various statistics if ut is an iid and we should use Phillips-Perron’s counterparts if it is not iid.
An indication as to whether the Z statistic should be used in addition to (or instead of) the ADF tests might be obtained in the diagnostic statistics from the DF and ADF regressions. If normality, autocorrelation or heterogeneity statistics are significant, one might adopt the Phillips-Perron approach. Furthermore, power may be adversely affected by misspecifying the lag length in the augmented Dickey-Fuller regression, although it is unclear how far this problem is mitigated by choosing the number of lags using data-based criteria, and the Z-tests have the advantage that this choice does not have to be made. Against this, one should avoid the use of the
Z test if the presence of negative moving average components is somehow suspected in the disturbances.
73
Download free eBooks at bookboon.com
73

Stationarity and Unit Roots Tests

Financial Econometrics

Under the null hypothesis that φ = 0, the PP Zt and Zφ statistics have the same asymptotic distributions as the ADF t-statistic and normalized bias statistics.
One advantage of the PP tests over the ADF tests is that the PP tests are robust to general forms of heteroskedasticity in the error term ut . Another advantage is that the user does not have to specify a lag length for the test regression.

4.3

Stationarity tests

The ADF and PP unit root tests are for the null hypothesis that a time series Yt is
I(1). Stationarity tests, on the other hand, are for the null that Yt is I(0). The most commonly used stationarity test, the KPSS test, is due to Kwiatkowski, Phillips,
Schmidt and Shin (1992) (KPSS). They derive their test by starting with the model
Yt = α + βt + µt + ut µt = µt−1 + εt ,

2 εt ∼ W N (0, σε )

where ut is I(0) and may be heteroskedastic.
2
The null hypothesis that Yt is I(0) is formulated as H0 : σε = 0, which implies that µt is a constant. Although not directly apparent, this null hypothesis also implies a unit moving average root in the ARMA representation of ∆Yt .

74
Download free eBooks at bookboon.com
74

Click on the ad to read more

Stationarity and Unit Roots Tests

Financial Econometrics

The KPSS test statistic is the Lagrange multiplier (LM) or score statistic for
2
2 testing σε = 0 against the alternative that σε > 0 and is given by
T

KP SS =

ˆ where St =

t j=1 1
ˆ
ˆ
S 2 /λ2
T 2 t=1 t

ˆ uj , ut is the residual of a regression Yt on t and λ2 .
ˆ ˆ t Critical values from the asymptotic distributions must be obtained by simulation methods. The stationary test is a one-sided right-tailed test so that one rejects the null of stationarity at the α level if the KPSS test statistic is greater than the
100(1 − α) quantile from the appropriate asymptotic distribution.

4.4

Example: Purchasing Power Parity

It is very easy to perform unit root and stationarity tests in EViews. As an example, consider a Purchasing Power Parity condition between two countries: USA and UK.
In efficient frictionless markets with internationally tradeable goods, the law of one price should hold. That is, st = p t − p ∗ , t where st is a natural logarithm of the spot exchange rate (price of a foreign currency in units of a domestic one), pt is a logarithm of the aggregate price index in the domestic country and p∗ is a log price in the foreign country. This condition is t referred to as absolute purchasing power parity condition.
This condition is usually verified by testing for non-stationarity of the real exchange rate qt = st + p∗ − pt . Before we perform this let us look at properties of t the constituent series.
We consider monthly data for USA and UK over the period from January 1989 to November 2008.
Although plots of both consumer price indices and the exchange rate indicate non-stationarity, we perform formal tests for unit root and stationarity.
In the dataset PPP.wf1, there are levels of the exchange rate and consumer price indices are given, so we need to create log series to carry out tests. This is done as usually, series lcpi_uk=log(cpi_uk) series lcpi_uk=log(cpi_uk) series lgbp_usd=log(gbp_usd)
75
Download free eBooks at bookboon.com
75

Stationarity and Unit Roots Tests

Financial Econometrics

Let us start with the UK consumer price index. We can find the option Unit Root
Tests... in the View section of the series object menu (double click on lcpi_uk icon).
In the Test Type box there is a number of tests available in EViews. We start with
Augmented-Dickey-Fuller test. As we are interested in testing for unit roots in levels of log consumer price index, we choose Test for unit root in levels in the next combo-box, and finally we select testing with both intercept and trend as it is the most general case.

Figure 4.1: Augmented Dickey-Fuller test dialog window

Excellent Economics and Business programmes at:

“The perfect start of a successful, international career.”
CLICK HERE

to discover why both socially and academically the University of Groningen is one of the best places for a student to be

www.rug.nl/feb/education 76
Download free eBooks at bookboon.com
76

Click on the ad to read more

Stationarity and Unit Roots Tests

Financial Econometrics

EViews will also select the most appropriate number of lags of the residuals to be included in the regression using the selected criteria (it is possible to specify a number of lags manually is necessary by ticking User specified option).
Click OK and EViews produces the following output

Figure 4.2: Output for the Augmented Dickey-Fuller test

The absolute value of the t-statistic does not exceed any of the critical values given below so we cannot reject the null hypothesis of the presence of unit root in the series.
Unfortunately, EViews provides only the test of the null hypothesis H0 : φ = 0.
One can perform more general test by estimating Dickey-Fuller regression (4.2.6).
In the command line type the following specification ls d(lcpi_uk) c lcpi_uk(-1) @trend(1989M01) to run the ADF regression with intercept and trend component. As you noted, the function @trend allows to include the time trend component that increases by one for each date in the workfile. The optional date argument 1989M01 is provided to indicate the starting date for the trend. We did not include any M A components in
77
Download free eBooks at bookboon.com
77

Stationarity and Unit Roots Tests

Financial Econometrics

the regression since based on the previous results (see Figure ??) zero lag is optimal according to the Schwartz selection criterium.
The regression output is identical with that produced by the Augmented
Dickey-Fuller test

Figure 4.3: Output of the regression-based procedure of the Augmented DickeyFuller test

However, the approach enables us to perform the Wald test of linear restrictions and specify the null hypothesis H0 : (β, φ) = (0, 0) (or more general, H0 : (α, β, φ) =
(0, 0, 0)).

Figure 4.4: Wald test results for the Augmented Dickey-Fuller test specifications

The value of Wald test statistic in the case of the null H0 : (β, φ) = (0, 0) is
1.7648; this has to be compared with the critical values tabulated in MacKinnon
(1996).
As the test statistic is smaller than all of the critical values, we cannot reject the null hypothesis, which confirms non-stationarity of the log consumer price index series. 78
Download free eBooks at bookboon.com
78

Stationarity and Unit Roots Tests

Financial Econometrics

This conclusion is also confirmed by other stationarity tests. For example, in
Kwiatkowski-Phillips-Schmidt-Shin test (specification with the intercept and trend), the test statistic is 0.4257 which is higher than the critical value at 1% significance level (which is 0.216). Thus, we reject the null hypothesis of stationarity of the series. If the Purchasing Power Parity condition holds one would expect the real exchange rate qt = st − pt + p∗ to be stationary and mean reverting. The presence of t unit root in the deviations series would indicate the existence of permanent shocks which do not disappear in a long run.
We create a series of deviations d=lgbp_usd-lcpi_uk-lcpi_us Augmented Dickey-Fuller does not reject the null hypothesis of the presence of unit root in the deviations series. Also, the value of Wald test statistic is 1.8844 indicates which confirms nonstationarity of the deviations from the Purchasing Power Parity condition. American online
LIGS University is currently enrolling in the
Interactive Online BBA, MBA, MSc,
DBA and PhD programs:

▶▶ enroll by September 30th, 2014 and
▶▶ save up to 16% on the tuition!
▶▶ pay in 10 installments / 2 years
▶▶ Interactive Online education
▶▶ visit www.ligsuniversity.com to find out more!

Note: LIGS University is not accredited by any nationally recognized accrediting agency listed by the US Secretary of Education.
More info here.
79
Download free eBooks at bookboon.com
79

Click on the ad to read more

Univariate Time Series: Volatility Models

Financial Econometrics

Chapter 5
Univariate Time Series: Volatility
Models
5.1

Introduction

In Chapter 3 we have considered approaches to modelling conditional mean of a univariate time series. However, many areas of financial theory are concerned with the second moment of time series – conditional volatility as a proxy for risk.
In this chapter we introduce time series models that represent the dynamics of conditional variances. In particular we consider ARCH, GARCH model as well as their extensions.
The reader is also referred to Engle (1982), Bollerslev (1986), Nelson (1991),
Hamilton (1994), Enders (2004), Zivot and Wang (2006).

5.2

The ARCH Model

Besides a time varying conditional mean of financial time series, most of them also exhibit changes in volatility regimes. This is especially applicable to many high frequency macroeconomic and financial time series.
While modelling such time series, we cannot use homoscedastic models. The simplest way to allow volatility to vary is to model conditional variance using a simple autoregressive (AR) process.
Let Yt denote a stationary time series, then Yt can be expressed as its mean plus a white noise:
Yt = c + ut

(5.2.1)

where c is the mean of Yt , and ut is i.i.d. with mean zero. To allow for conditional
80

Download free eBooks at bookboon.com
80

Univariate Time Series: Volatility Models

Financial Econometrics

heteroscedasticity, assume that
2
vart−1 [ut ] = σt .

Here vart−1 denotes the variance conditional on information at time t − 1, and is modelled in the following way:
2
σt = α0 + α1 u2 + ... + αp u2 . t−1 t−p

(5.2.2)

In order to show that this specification is equivalent to AR representation of squared
2
residuals, note that vart−1 [ut ] = E u2 t−1 = σt since E[ut ] = 0. Thus, equation
(5.2.2) can be rewritten as: u2 = α0 + α1 u2 + ... + αp u2 + εt , t t−1 t−p (5.2.3)

where εt = u2 − Et−1 [u2 ] is a zero mean white noise process. The model in (5.2.1) t t and (5.2.3) is known as the autoregressive conditional heteroscedasticity (ARCH) model of Engle (1982), which is usually referred to as the ARCH(p) model. More generally, ARCH model can be rewritten as
Y t = c + ut u t = σ t ηt
2
σt = α0 + α1 u2 + ... + αp u2 , t−1 t−p

where ηt is an iid normal random variable.

5.2.1

Example: Simulating an ARCH(p) model in EViews

It is relatively easy to simulate ARCH process in EViews. Let us consider as example the following ARCH(2) model
Y t = σ t ηt
2
2
2
σt = 3.5 + 0.5Yt−1 + 0.48Yt−2

(5.2.4)

with ηt being independent random variables following N (0, 1)distribution. Similarly to ARMA process we need to generate error term process ηt and first two initial values of Yt after which the whole process can be simulated. Create a new workfile and in the command line enter smpl @all series eta=nrnd smpl @first @first+1
81
Download free eBooks at bookboon.com
81

Univariate Time Series: Volatility Models

Financial Econometrics

series y=@sqrt(3.5/(0.5+0.48))*eta series y=@sqrt(3.5/(0.5+0.48))*eta smpl @first+2 @last smpl @first+2 @last ∧ y=@sqrt(3.5+0.5*y(-1) 2+0.48*y(-2)∧ 2)*eta y=@sqrt(3.5+0.5*y(-1)∧ 2+0.48*y(-2)∧ 2)*eta smpl @all smpl @all
The last statement is included to ensure that we come back the whole data range.
The last statement is included is ensure that following figure.
The plot of the simulated series to given in the we come back the whole data range.
The plot of the simulated series is given in the following figure.

Figure 5.1: Plot of simulated ARCH process
Figure 5.1: Plot of simulated ARCH process

82
82

.

Download free eBooks at bookboon.com
82

Click on the ad to read more

Univariate Time Series: Volatility Models

Financial Econometrics

Visually, the process looks stationary, mean reverting and with zero mean as expected from the equation (5.2.4).
Testing for ARCH Effects In order to test for the presence of ARCH effects in the residuals, we can use AR representation of squared residuals in the following way. Based on equation (5.2.2), construct an auxiliary regression
ˆt−1
ˆt−p u2 = α0 + α1 u2 + ... + αp u2 + εt ,
ˆt

(5.2.5)

. The significance of parameters αi would indicate the presence of conditional volatility. Under the null hypothesis that there are no ARCH effects: α1 = α2 = ... = αp = 0, a the test statistic LM = T R2 ∼ χ2 where T is the sample size and R2 is computed p from the regression (5.2.5).

5.3

The GARCH Model

More general form of conditional volatility is based on ARMA specification as an extension of AR process of squared residuals. Bollerslev (1986) introduces GARCH model (which stands for generalized ARCH) where he replaces the AR model in
(5.2.2) by: p 2 σt q

α i u2 t−i = α0 +

2 βi σt−j ,

+

i=1

(5.3.1)

j=1

where the coefficients αi and βj are positive to ensure that the conditional variance
2
σt is always positive. In order to emphasize the number of lags used in (5.3.1) we denote the model by GARCH(p, q).
When q = 0, the GARCH model reduces to the ARCH model. Under the
2
GARCH(p, q) model, the conditional variance of ut , σt , depends on the squared residuals in the previous p periods, and the conditional variance in the previous q periods. The most commonly used model is a GARCH(1, 1) model with only three parameters in the conditional variance equation.
A GARCH model can be expressed as an ARMA model of squared residuals.
For example, for a GARCH(1, 1) model:
2
2 σt = α0 + α1 u2 + β1 σt−1 . t−1 2
Since Et−1 [u2 ] = σt , the above equation can be rewritten as: t u2 = α0 + (α1 + β1 )u2 + εt − β1 εt−1 , t t−1
83
Download free eBooks at bookboon.com
83

(5.3.2)

Univariate Time Series: Volatility Models

Financial Econometrics

which is an ARM A(1, 1) model. Here εt = u2 − Et−1 [u2 ] is the white noise error t t term. Given the ARMA representation of the GARCH model, we conclude that stationarity of the GARCH(1, 1) model requires α1 + β1 < 1. The unconditional variance of ut is given by var[ut ] = E u2 = α0 /(1 − α1 − β1 ), t Indeed, from (5.3.2)
E u2 = α0 + (α1 + β1 )E u2 t t−1 and thus E [u2 ] = α0 + (α1 + β1 )E[u2 ] since u2 is stationary. For the general t t t GARCH(p, q) model (5.3.2), the squared residuals u2 behave like an ARM A(max(p, q), q) t process.
One can identify the orders of the GARCH model using the correlogram of the squared residuals. They will coincide with ARMA orders of the squared residuals of the time series.
GARCH Model and Stylized Facts In practice, researchers have uncovered many so-called stylized facts about the volatility of financial time series; Bollerslev,
Engle and Nelson (1994) give a complete account of these facts. Using the ARMA representation of GARCH models shows that the GARCH model is capable of explaining many of those stylized facts. This section will focus on three important ones: volatility clustering, fat tails, and volatility mean reversion. Other stylized facts are illustrated and explained in later sections.
Volatility Clustering Usually the GARCH coefficient β1 is found to be around 0.9 for many weekly or daily financial time series. Given this value of β1 , it
2
2 is obvious that large values of σt−1 will be followed by large values of σt , and small
2
2 values of σt−1 will be followed by small values of σt . The same reasoning can be obtained from the ARMA representation in (5.3.2), where large/small changes in
2
u2 will be followed by large/small changes in σt . t−1 Fat Tails It is well known that the distribution of many high frequency financial time series usually have fatter tails than a normal distribution. This means that large changes are more often to occur than under a normal distribution. Thus a GARCH model can replicate the fat tails usually observed in financial time series.
Volatility Mean Reversion Although financial markets may experience excessive volatility from time to time, it appears that volatility will eventually settle down to a long run level. The previous subsection showed that the long run variance of ut for the stationary GARCH(1, 1) model is α0 /(1 − α1 − β1 ). In this case, the volatility is always pulled toward this long run level.
84
Download free eBooks at bookboon.com
84

Univariate Time Series: Volatility Models

Financial Econometrics

5.3.1

Example: Simulating an GARCH(p, q) model in EViews

It is slightly trickier to simulate GARCH process than the ARCH one in EViews.
Since it is necessary simultaneously to generate Yt and σt processes, we will need to use loop to accomplish it. Therefore, it is more convenient to use program object rather than doing it in the command line. Consider as an example GARCH(2, 1) series Yt = σ t η t
2
2
2
2 σt = 3.5 + 0.5Yt−1 + 0.28Yt−2 + 0.2σt−1

(5.3.3)

We start the program with the same commands as in the ARCH case; the only difference is that we generate a conditional variance process s. smpl @all series eta=nrnd scalar n=@obs(eta) smpl @first @first+1 series s=3.5/(0.5+0.28+0.2) series y=@sqrt(s)*eta

Join the best at the Maastricht University
School of Business and
Economics!

Top master’s programmes
•  3rd place Financial Times worldwide ranking: MSc
3
International Business
• 1st place: MSc International Business
• 1st place: MSc Financial Economics
• 2nd place: MSc Management of Learning
• 2nd place: MSc Economics
•  nd place: MSc Econometrics and Operations Research
2
•  nd place: MSc Global Supply Chain Management and
2
Change
Sources: Keuzegids Master ranking 2013; Elsevier ‘Beste Studies’ ranking 2012;
Financial Times Global Masters in Management ranking 2012

Visit us and find out why we are the best!
Master’s Open Day: 22 February 2014

Maastricht
University is the best specialist university in the
Netherlands
(Elsevier)

www.mastersopenday.nl

85
Download free eBooks at bookboon.com
85

Click on the ad to read more

Univariate Time Series: Volatility Models

Financial Econometrics

2
The next part of the program creates the loop where both series Yt and σt are generated observation after observation.

for !i=2 to n-2 smpl @first+!i @first+!i s=3.5+0.5*y(-1)∧ 2+0.28*y(-2)∧ 2+0.2*s(-1) y=@sqrt(s)*eta next smpl @all
The graph of the simulated GARCH process is given on Figure ??.

Figure 5.2: Plot of the simulated GARCH process

We can see on the graph a clear effect of volatility clustering. In most cases volatility stays low but there are several spikes with high volatility which persist for a number of periods. Another stylized fact can be seen from the histogram of the simulated observations (click on View/Descriptive Statistic and Tests/Histogram and Stats). Jarque-Bera test strongly rejects the null hypothesis of normality and the kurtosis is extremely high indicating fat tails of the generated distribution.

5.4

GARCH model estimation

This section illustrates how to estimate a GARCH model. Assuming that ut follows normal or Gaussian distribution conditional on past history, the prediction error
86
Download free eBooks at bookboon.com
86

Univariate Time Series: Volatility Models

Financial Econometrics

Figure 5.3: Histogram of the simulated GARCH process

decomposition of the log-likelihood function of the GARCH model conditional on initial values is:
T

T

1
1
u2
T
t
2
log σt −
.
log L = − log(2π) −
2
2
2 i=1
2 i=1 σt
The unknown model parameters c, αi (i = 0, ..., p) and βj , (j = 1, ..., q) can be estimated using conditional maximum likelihood estimation (MLE). Details of the maximization are given in Hamilton (1994). Once the MLE estimates of the parameters are found, estimates of the time varying volatility σ2 (t = 1, ..., T ) are also obtained as a side product.

5.5

GARCH Model Extensions

In many cases, the basic GARCH model (5.3.2) provides a reasonably good model for analyzing financial time series and estimating conditional volatility. However, there are some aspects of the model which can be improved so that it can better capture the characteristics and dynamics of a particular time series.
In the basic GARCH model, since only squared residuals u2 enter the equat−i tion, the signs of the residuals or shocks have no effects on conditional volatility.
However, a stylized fact of financial volatility is that bad news (negative shocks) tends to have a larger impact on volatility than good news (positive shocks).
87
Download free eBooks at bookboon.com
87

Univariate Time Series: Volatility Models

Financial Econometrics

5.5.1
5.5.1

EGARCH Model
EGARCH Model

Nelson (1991) proposed the following exponential
Nelson (1991) proposed the following exponential allow for leverage effects: allow for leverage effects: p |ut−i | + γi ut−i ht = α0 + p αi |ut−i | + γi ut−i σt−i ht = α0 + i=1 αi σt−i i=1

GARCH (EGARCH) model to
GARCH (EGARCH) model to
+
+

q q ht−j ,

i=1 ht−j , i=1 2 where ht = log σt . Note that when ut−i is positive, the total effect of ut−i is (1 +
2
where ht = log σt . Note that when ut−i is positive, the total effect of ut−i is (1 + γi )|ut−i |; in contrast, when ut−i is negative, the total effect of ut−i is (1 − γi )|ut−i |. γi )|u |; in contrast, when ut−i is negative, the total effect of ut−i is (1 − γi )|ut−i |.
Bad t−i news can have a larger impact on volatility, and the value of γi would be
Bad news can have a larger impact on volatility, and the value of γi would be expected to be negative. expected to be negative.

5.5.2
5.5.2

TGARCH Model
TGARCH Model

Another GARCH variant that is capable of modeling leverage effects is the threshold
Another GARCH variant that is capable of modeling leverage effects is the threshold
GARCH (TGARCH) model, which has the following form:
GARCH (TGARCH) model, which has the following form:
2
σt
2
σt

where where = α0 +
= α0 +

p p α i u2 t−i 2 i=1 αi ut−i i=1 St−i =
St−i =

+
+

p p αi St−i u2 t−i 2 i=1 αi St−i ut−i i=1 1
1
0
0

ut−i ut−i ut−i ut−i +
+

q q 2 βj σt−j ,
2
j=1 βj σt−j , j=1 p. The forecasts are unbiased since all of the forecast errors have expectation zero and the MSE matrix for Yt+h|T is h−1 Σ(h) = M SE YT +h − YT +h|T =

Ψs ΣΨs . s=0 The h-step forecast in the case of estimated parameters is
ˆ
ˆ ˆ
ˆ ˆ
YT +h|T = Π1 YT +h−1|T + ... + Πp YT +h−p|T ,
ˆ
where Πj are the estimated matrices of parameters. The h-step forecast error is now h−1 ˆ
YT +h − YT +h|T =

s=0

ˆ
Ψs εT +h−s + Yt+h − YT +h|T

The estimate of the MSE matrix of the h-step forecast is then h−1 ˆ ˆˆ
Ψs ΣΨs

ˆ
Σ(h) = s=0 with Ψs =

s

ˆ
ˆ
Ψs−j Πj .

j=1

6.1.2

Granger Causality

One of the main uses of VAR models is forecasting. The structure of the VAR model provides information about a variable’s or a group of variables’ forecasting ability for other variables. The following intuitive notion of a variable’s forecasting ability is due to Granger (1969). If a variable, or group of variables, Y1 is found to be helpful for predicting another variable, or group of variables, Y2 then Y1 is said to Granger-cause Y2 ; otherwise it is said to fail to Granger-cause Y2 . Formally, Y1 fails to Granger-cause Y2 if for all s > 0 the MSE of a forecast of Y2,t+s based on (Y2,t , Y2,t−1 , ...) is the same as the MSE of a forecast of Y2,t+s based on
(Y2,t , Y2,t−1 , ...) and (Y1,t , Y1,t−1 , ...). Note that the notion of Granger causality only implies forecasting ability.
In a bivariate V AR(p) model for Yt = (Y1t , Y2t ) , Y2 fails to Granger-cause Y1 if all of the p VAR coefficient matrices Π1 , ..., Πp are lower triangular. That is, all of the coefficients on lagged values of Y2 are zero in the equation for Y1 . The p linear coefficient restrictions implied by Granger non-causality may be tested using the
Wald statistic. Notice that if Y2 fails to Granger-cause Y1 and Y1 fails to Grangercause Y2 , then the VAR coefficient matrices Π1 , ..., Πp are diagonal.
98
Download free eBooks at bookboon.com
98

Multivariate Time Series Analysis

Financial Econometrics

6.1.3

Impulse Response and Variance Decompositions

As in the univariate case, a V AR(p) process can be represented in the form of a vector moving average (VMA) process.
Yt = µ + ut + Ψ1 ut−1 + Ψ2 ut−2 + ..., where the k ×k moving average matrices Ψs are determined recursively using (6.1.3).
The elements of coefficient matrices Ψs mean effects of ut−s shocks on Yt . s That is, the (i, j)-th element, ψij , of the matrix Ψs is interpreted as the impulse response ∂Yi,t+s
∂Yi,t
s
=
= ψij , i, j = 1, ..., T.
∂uj,t
∂uj,t−s s Sets of coefficients ψij (s) = ψij , i, j = 1, ..., T are called the impulse response functions. It is possible to decompose the h-step-ahead forecast error variance into the proportions due to each shock ujt .
The forecast variance decomposition determines the proportion of the variation
Yjt due to the shock ujt versus shocks of other variables uit for i = j.

99
Download free eBooks at bookboon.com
99

Click on the ad to read more

Multivariate Time Series Analysis

Financial Econometrics

6.1.4

VAR in EViews

As an example of VAR estimation in EViews, consider two time series of returns of monthly IBM stocks and the market portfolio returns from Fama-French database
(data is contained in IBM1.wf1).
There are several ways to estimate VAR model in EViews. The first one is through the main menu. Clicking on View/Estimate VAR... will open a dialog window for VAR model estimation.

Figure 6.1: VAR model estimation dialog window

We choose Unrestricted VAR and in the Endogenous Variables box we have to specify the list of endogenous time series variables to be included in the
VAR model. We consider two excess return series of the IBM stock IBM_ex and the market portfolio Mkt_ex.
In the Lag Intervals for Endogenous we have to specify the order of the model, that is interval of lags to be included in the model. If we want to build a model with only two lags, we write 1 2. This means, we include all lags beginning from the first one and ending with the lag of order 2. We do not specify any exogenous variables apart from the intercept term c.
Another way of calling the VAR estimation dialog window is to select both endogenous variables in the workfile and in the context menu (right button click) choose Open/as VAR.... The Endogenous Variables box will be filled in automatically.
Finally, we can estimate VAR model from the command line. There is a separate object, called var, to declare the VAR model. The estimation of the above mentioned example will look like
100
Download free eBooks at bookboon.com
100

Multivariate Time Series Analysis

Financial Econometrics

var ibm2.ls 1 2 ibm_ex mkt_ex
Here ibm2 is a name of the var-object which will be saved in the workfile, ls indicates the estimation method; in this case it is OLS estimation method of the unrestricted
VAR model. Then, specifications of the lags pairs and the list of endogenous variables follow. If one wishes to include exogenous variables besides the intercept, it can be done by typing a symbol @ followed by a list of exogenous variables. For example, var ibm2.ls 1 2 ibm_ex mkt_ex @ exvar1 exvar2
Click OK and EViews produces an estimation output for the specified VAR model.

Figure 6.2: Output for the VAR model estimation

Two columns correspond to two equation in the VAR model. The only significant coefficient besides the intercept one is at the second lag of the market portfolio
101
Download free eBooks at bookboon.com
101

Multivariate Time Series Analysis

Financial Econometrics

returns in the IBM equation. As expected, there is a unidirectional dynamic relationship from the market portfolio returns to the IBM returns, Thus, the IBM return is affected by the past movements of the market while past movements of IBM stock returns do not affect the market portfolio returns. The second equation (for market portfolio) is not significant as suggested by the F-statistics. This means that the the estimated model cannot explain variation in the market portfolio returns. This can happen because we possibly omitted some important exogenous variables or the order of the model is inappropriately selected. EViews provides a tool to choose the most suitable lag order. In the workfile menu choose View/Lag Structure/Lag
Length Criteria... to determine the optimal model structure. In the appeared
Lag Specification window we choose pmax = 8 (maximal lag order).
All criteria indicate that the optimal lag order of the model is 0. This means that the VAR model is inappropriate model to explain IBM and market portfolio returns. Indeed, we know from the CAPM that market portfolio returns affect the stock returns contemporaneously and are not in lag relationship. Thus, either additional exogenous factors should be found to include in the model or another structure of the model should be employed in this case.

102
Download free eBooks at bookboon.com
102

Click on the ad to read more

Multivariate Time Series Analysis

Financial Econometrics

Figure 6.3: Output for the lag length selection procedure

Lag selection can be programmed manually in the same way as it is done for
ARMA model (see Chapter 3). There are some command references given below which can be used to assess various statistic values in the VAR analysis in EViews.

6.2

Cointegration

The assumption of stationary of regressors and regressands is crucial for the properties and the OLS estimators discussed in Chapter 2. In this case, the usual statistical results for the linear regression model and consistency of estimators hold. However, when variables are non-stationary then the usual statistical results may not hold.

6.2.1

Spurious Regression

If there are trends in the data (deterministic or stochastic) this can lead to a spurious results when running OLS regression. This is because time trend will dominate other stationary variables and the OLS estimators will pick up covariances generated by time trends only. While the effects of deterministic trends can be removed from the regression by either including time trend regressor or simply de-trending variables, non-stationary variables with stochastic trends may lead to invalid inferences.
103
Download free eBooks at bookboon.com
103

Multivariate Time Series Analysis

Financial Econometrics

Var Data Members
Data Member

Description

@eqlogl(k)

log likelihood for equation k

@eqncoef(k)

number of estimated coefficients in equation k

@eqregobs(k)

number of observations in equation k

@meandep(k)

mean of the dependent variable in equation k

@r2(k)

R-squared statistic for equation k

@rbar2(k)

adjusted R-squared statistic for equation k

@sddep(k)

standard deviation of dependent variable in equation k

@se(k)

standard error of the regression in equation k

@ssr(k)

sum of squared residuals in equation k

@aic

Akaike information criterion for the system

@detresid

determinant of the residual covariance matrix

@hq

Hannan-Quinn information criterion for the system

@logl

log likelihood for system

@ncoefs

total number of estimated coefficients in the var

@neqn

number of equations

@regobs

number of observations in the var

@sc

Schwarz information criterion for the system

@svarcvgtype

Returns an integer indicating the convergence type of the structural decomposition estimation: 0 (convergence achieved), 2 (failure to improve), 3 (maximum iterations reached), 4 (no convergence-structural decomposition not estimated)

@svaroverid

over-identification LR statistic from structural factorization

@totalobs

sum of "@eqregobs" from each equation ("@regobs*@neqn")

@coefmat

coefficient matrix (as displayed in output table)

@coefse

matrix of coefficient standard errors (corresponding to the output table)

@impfact

factorization matrix used in last impulse response view

@lrrsp

accumulated long-run responses from last impulse response view

@lrrspse

standard errors of accumulated long-run responses

@residcov

covariance matrix of the residuals

@svaramat

estimated A matrix for structural factorization

@svarbmat

estimated B matrix for structural factorization

@svarcovab

covariance matrix of stacked A and B matrix for structural factorization

@svarrcov

restricted residual covariance matrix from structural factorization

Consider, for example, u1,t ∼ IN (0, 1)

Y1,t = Y1,t−1 + u1,t ,

u2,t ∼ IN (0, 1)

Y2,t = Y2,t−1 + u2,t ,

Both of the variables are non-stationary and independent from each other. In the regression Y1,t = β0 + β1 Y2,t + εt , the value of true slope parameter β1 = 0. Thus,
ˆ
the value of the OLS estimate β1 should be insignificant. The actual estimations produce high R2 coefficients and highly significant β1 .
The problem with the spurious regression is that t- and F-statistics do not
ˆ
follow standard distributions. As shown in Phillips (1986), β1 does not converge in
104
Download free eBooks at bookboon.com
104

Multivariate Time Series Analysis

Financial Econometrics

probability to zero, R2 converges to unity as T → ∞ so that the model will appear to fit well even though it is misspecified.
Regression with I(1) data only makes sense when the data are cointegrated.

6.2.2

Cointegration

Let Yt = (Y1t , ..., Ykt ) denote an k × 1 vector of I(1) time series. Yt is cointegrated if there exists an k × 1 vector β = (β1 , ..., βk ) such that
Zt = β Yt = β1 Y1t + ... + βk Ykt ∼ I(0).

(6.2.1)

The non-stationary time series in Yt are cointegrated if there is a linear combination of them that is stationary. If some elements of β are equal to zero then only the subset of the time series in Yt with non-zero coefficients is cointegrated.
There may be different vectors β such that Zt = β Yt is stationary. In general, there can be 0 < r < k linearly independent cointegrating vectors. All cointegrating vectors form a cointegrating matrix B. This matrix is again not unique. Some normalization assumption is required to eliminate ambiguity from the definition.

Challenge the way we run

EXPERIENCE THE POWER OF
FULL ENGAGEMENT…
RUN FASTER.
RUN LONGER..
RUN EASIER…

READ MORE & PRE-ORDER TODAY
WWW.GAITEYE.COM

105
Download free eBooks at bookboon.com
1349906_A6_4+0.indd 1

22-08-2014 12:56:57

105

Click on the ad to read more

Multivariate Time Series Analysis

Financial Econometrics

A typical normalization is β = (1, −β2 , ..., −βk ) so that the cointegration relationship may be expressed as
Zt = β Yt = Y1t − β2 Y2t − ... − βk Ykt ∼ I(0).

6.2.3

Error Correction Models

Engle and Granger (1987) state that if a bivariate I(1) vector Yt = (Y1t , Y2t ) is cointegrated with cointegrating vector β = (1, −β2 ) then there exists an error correction model (ECM) of the form
∆Y1t = δ1 + φ1 (Y1,t−1 − β1 Y2,t−1 +
∆Y2t = δ2 + φ2 (Y1,t−1 − β2 Y2,t−1 +

j α11 ∆Y1,t−j +

j α12 ∆Y2,t−j + ε1t (6.2.2) s=1 j=1 j α21 ∆Y1,t−j

j α22 ∆Y2,t−j + ε2t (6.2.3)

+ s=1 j=1

that describes the long-term relations of Y1t and Y2t . If both time series are I(1) but are cointegrated (have a long-term stationary relationship), there is a force that brings the error term back towards zero. If the cointegrating parameter β1 or β2 is known, the model can be estimated by the OLS method.

6.2.4

Tests for Cointegration: The Engle-Granger Approach

Engle and Granger (1987) show that if there is a cointegrating vector, a simple two-step residual-based testing procedure can be employed to test for cointegration.
In this case, a long-run equilibrium relationship between components of Yt can be estimated by running
(6.2.4)
Y1,t = βY2,t + ut , where Y2,t = (Y2,t , ..., Yk,t ) is an (k − 1) × 1 vector. To test the null hypothesis that
ˆ
Yt is not cointegrated, we should test whether the residuals ut ∼ I(1) against the alternative ut ∼ I(0). This can be done by any of the tests for unit roots. The
ˆ
most commonly used is the augmented Dickey-Fuller test with the constant term and without the trend term. Critical values for this test is tabulated in Phillips and
Ouliaris (1990) or MacKinnon (1996).
Potential problems with Engle-Granger approach is that the cointegrating vector will not involve Y1,t component. In this case the cointegrating vector will not be consistently estimated from the OLS regression leading to spurious results. Also, if
106
Download free eBooks at bookboon.com
106

Multivariate Time Series Analysis

Financial Econometrics

there are more than one cointegrating relation, the Engle-Granger approach cannot detect all of them.
Estimation of the static model (6.2.4) is equivalent to omitting the short-term components from the error-correction model (6.2.3). If this results for autocorrelation in residuals, although the results will still hold asymptotically, it might create a severe bias in finite samples. Because of this, it makes sense to estimate the full dynamic model. Since all variables in the ECM are I(0), the model can be consistently estimated using the OLS method. This approach leads to a better performance as it does not push the short-term dynamics into residuals.

6.2.5

Example in EViews: Engle-Granger Approach

Consider as an example the Forward Premium Puzzle. Due to rational expectation hypothesis, forward rate should be unbiased predictor of future spot exchange rate.
This means that in the regression of levels of spot St+1 on forward rate Ft the intercept coefficient should be equal to zero and the slope coefficient should be equal to unity.
Consider monthly data of the USG/GBP spot and forward exchange rate for the period from January 1986 to November 2008 (the data is in FPP.wf1 file).

107
Download free eBooks at bookboon.com
107

Click on the ad to read more

Multivariate Time Series Analysis

Financial Econometrics

Unit roots are often found in in levels of spot and forward exchange rates.
Augmented Dickey-Fuller test statistic values are -2.567 and -2.688 which are high enough to fail rejecting the null hypothesis at 5% significance level. Phillips-Perron test produces test statistic which value os on the border of the rejection region.
Thus, if two series are not cointegrated, there is a danger to obtain spurious results from the OLS regression. However, if we look at plots of the two series we can see that they co-move together very closely, so we can expect existence of cointegrating relation between them.

Figure 6.4: Plots of forward and future spot USD/GBP exchange rates

St+1

To perform Engle-Granger test for cointegration let us run OLS regression
= βFt + ut in EViews and generate residuals from the model. ls f_spt fwd series resid1=resid

The second step is to test the residuals for stationarity. Augmented Dickey-Fuller test strongly rejects the presence of a unit root in the residual series in the favour of stationarity hypothesis.
Similar results are generated by other testing procedures. Thus, we conclude that future spot and forward exchange rates are cointegrated. Hence, the OLS results are valid for the regression in levels as well. In this case the slope coefficient is equal to 0.957 which is positive and close to unity. However, we reject the null hypothesis H0 : β1 = 1 with the Wald test.
Thus, the forward premium puzzle also exists even for the model in levels for the exchange rates.
108
Download free eBooks at bookboon.com
108

Multivariate Time Series Analysis

Financial Econometrics

Figure 6.5: Results of Augmented Dickey-Fuller test for residuals from the longrun equilibrium relationship

Figure 6.6: Wald test results for testing H0 : β1 = 1

Another way of estimating cointegrating equation is to estimate a vector error correction model. To do this, open both forward and spot series as VAR system
(select both series and in the context menu choose Open/as VAR...). In the VAR type box select Vector Error Correction and in the Cointegration tab click on
Intercept (no trend) in CE - no intercept in VAR. EViews’ output is given in Figure ??.
As expected, the output shows that the stationary series is approximately
St+1 − Ft with the mean around zero. Deviations from the long-run equilibrium equation have significant effect on changes of the spot exchange rate. Another
1
highly significant coefficient α22 indicates a significant impact of ∆St on ∆Ft which is not surprising. This underlies the relationships between the spot and forward rate through the Covered Interest rate Parity condition (CIP).
The following subsection introduces an approach of testing for cointegration
109
Download free eBooks at bookboon.com
109

Multivariate Time Series Analysis

Financial Econometrics

Figure 6.7: Output of the vector error correction model

when there exists more than one cointegrating relationship.

6.2.6

Tests for Cointegration: The Johansen’s Approach

An alternative approach to test for cointegration was introduced by Johansen (1988).
His approach allows to avoid some drawbacks existing in the Engle-Granger’s approach and test the number of cointegrating relations directly. The method is based on the VAR model estimation.
Consider the V AR(p) model for the k × 1 vector Yt
Yt = Π1 Yt−1 + ... + Πp Yt−p + ut ,

t = 1, ..., T,

(6.2.5)

where ut ∼ IN (0, Σ).
Since levels of time series Yt might be non-stationary, it is better to transform
Equation (6.2.5) into a dynamic form, calling vector error correction model (VECM)
∆Yt = ΠYt−1 + Γ1 ∆Yt−1 + ... + Γp−1 ∆Yt−p+1 + ut , where Π = Π1 + ... + Πp − In and Γk = −

p j=k+1 Πj , k = 1, ..., p − 1.

110
Download free eBooks at bookboon.com
110

Multivariate Time Series Analysis

Financial Econometrics

Let us assume that Yt contains non-stationary I(1) time series components.
Then in order to get a stationary error term ut , ΠYt−1 should also be stationary.
Therefore, ΠYt−1 must contain r < k cointegrating relations. If the V AR(p) process has unit roots then Π has reduced rank rank(Π) = r < k. Effectively, testing for cointegration is equivalent to checking out the rank of the matrix Π.
If Π has a full rank then all time series in Y are stationary, if the rank of Π is zero then there are no cointegrating relationships.
If 0 < rank (Π) = r < k. This implies that Yt is I(1) with r linearly independent cointegrating vectors and k − r non-stationary vectors. Since Π has rank r it can be written as the product
Π = α

(k×k)

β ,

(k×r)(r×k)

where α and β are k × r matrices with rank(α) = rank(β) = r. The matrix β is a matrix of long-run coefficients and α represents the speed of adjustment to disequilibrium. The VECM model becomes
∆Yt = αβ Yt−1 + Γ1 Yt−1 + ... + Γp−1 ∆Yt−p+1 + ut ,

(6.2.6)

with β Yt−1 ∼ I(0).

www.sylvania.com

We do not reinvent the wheel we reinvent light. Fascinating lighting offers an infinite spectrum of possibilities: Innovative technologies and new markets provide both opportunities and challenges.
An environment in which your expertise is in high demand. Enjoy the supportive working atmosphere within our global group and benefit from international career paths. Implement sustainable ideas in close cooperation with other specialists and contribute to influencing our future. Come and join us in reinventing light every day.

Light is OSRAM

111
Download free eBooks at bookboon.com
111

Click on the ad to read more

Multivariate Time Series Analysis

Financial Econometrics

Johansen’s methodology of obtaining estimates of α and β is given below.
Johansen’s Methodology
Specify and estimate a V AR(p) model (6.2.5) for Yt .
Determine the rank of Π; the maximum likelihood estimate for β equals the matrix of eigenvectors corresponding to the r largest eigenvalues of a k × k residual matrix (see Hamilton (1994), Lutkepohl (1991), Harris (1995) for more detailed description). Construct likelihood ratio statistics for the number of cointegrating relationˆ
ˆ
ˆ ships. Let estimated eigenvalues are λ1 > λ2 > ... > λk of the matrix Π.
Johansen’s likelihood ratio statistic tests the nested hypotheses
H0 : r ≤ r0 vs. H1 : r > r0
The likelihood ratio statistic, called the trace statistic, is given by k LRtrace (r0 ) = −T

i=r0 +1

ˆ log 1 − λi .

It checks whether the smallest k − r0 eigenvalues are statistically different from zero.
ˆ
ˆ
If rank (Π) = r0 then λr0 +1 , ..., λk should all be close to zero and LRtrace (r0 ) should
ˆ
ˆ be small. In contrast, if rank (Π) > r0 then some of λr0 +1 , ..., λk will be nonzero (but less than 1) and LRtrace (r0 ) should be large.
We can also test H0 : r = r0 against H1 : r0 = r0 + 1 using so called the maximum eigenvalue statistic
ˆ
LRmax (r0 ) = −T log 1 − λr0 +1 .
Critical values for the asymptotic distribution of LRtrace (r0 ) and LRmax (r0 ) statistics are tabulated in Osterwald-Lenum (1992) for k − r0 = 1, ..., 10.
In order to determine the number of cointegrating vectors, first test H0 : r0 = 0 against the alternative H1 : r0 > 0. If this null is not rejected then it is concluded that there are no cointegrating vectors among the k variables in Yt . If H0 : r0 = 0 is rejected then there is at least one cointegrating vector. In this case we should test
H0 : r0 ≤ 1 against H1 : r0 > 1. If this null is not rejected then we say that there is only one cointegrating vector. If the null is rejected then there are at least two cointegrating vectors. We test H0 : r0 ≤ 2 and so on until the null hypothesis is not rejected. In a small samples tests are biased if asymptotic critical values are used without a correction. Reinsel and Ahn (1992) and Reimars (1992) suggested small samples bias correction by multiplying the test statistics with T − kp instead of T in the construction of the likelihood ratio tests.
112
Download free eBooks at bookboon.com
112

Multivariate Time Series Analysis

Financial Econometrics

6.2.7

Example in EViews: Johansen’s Approach

A very good example of a model with several cointegrating equations has been given by Johansen and Juselius (1990) (1992) (see also Harris (1995)). They considered a single equation approach to combine both Purchasing Power Parity and Uncovered
Interest rate Parity condition in one model.
In this model we expect two cointegrating equations between the UK consumer price index P , the US consumer price index P ∗ , USD/GBP exchange rate S and two interest rates I and I ∗ in the domestic and foreign countries respectively. If we denote their log counterparts by the corresponding small letter, the theory suggest that the following two relationships should hold in efficient markets with rational investors: pt − p∗ = st and ∆st+1 = it − i∗ . The data is considered within the range t t from January 1989 to November 2008 is given in PPPFP1.wf1 file.
We create the log counterparts of the variables in the standard ways, like series lcpi_uk=log(cpi_uk) and so on. In order to check for cointegration we can either estimate VECM
(open 5 series as VAR model) or create a Group with the variables. Johansen and
Juselius (1990) included into the model seasonal dummy variables as well as crude oil prices. We restrict ourself with only seasonal dummy for simplicity. We can create dummy variables by using a command @expand, which allows to create a group of dummy variables by expanding out one or more series into individual categories.
For this purposes we need first to create a variable indicating the quarter of the observation. We do it in the following way series quarter=@quarter(cpi_uk)
The command @quarter returns the quarter of the year in which the current observation begins. The second step is to create the dummy variables: group dum=@expand(quarter)
EViews will create a new group object dum containing four dummy variables for each of the quarter of the observation.
In both cases, either with VAR or with group objects, one can perform Johansen’s test procedure by clicking on View/Cointegration Test....
The dialog window will ask offer to specify the form of the VECM and the cointegrating equation (with or without intercept or trend components). We choose the first option with no trend and intercept to avoid perfect collinearity since we include four dummy variables as exogenous in the model. In the box Exogenous
Variables enter the name of the dummy variables group dum.
In the box Lag Intervals for D(Endogenous) we set 1 4 – we include 4 lags
113
Download free eBooks at bookboon.com
113

Multivariate Time Series Analysis

Financial Econometrics

360° thinking Figure 6.8: Johansen’s Cointegration test dialog window

.

in the model. This is determined by EViews as optimal according to 3 criteria (first estimate VAR with any of the lag specifications, check the optimality of the lag order in View/Lag Structure/Lag Specification/Lag Length Criteria and then re-estimate the VECM with the optimal lag order).

360° thinking .

360° thinking .

Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Discover the truth at www.deloitte.ca/careers
114

© Deloitte & Touche LLP and affiliated entities.

Download free eBooks at bookboon.com
114
Discover the truth at www.deloitte.ca/careers

© Deloitte & Touche LLP and affiliated entities.

Click on the ad to read more

© Deloitte & Touche LLP and affiliated entities.

D

Multivariate Time Series Analysis

Financial Econometrics

Figure 6.9: Output for Johansen’s Cointegration test

EViews produces results for various hypothesis tested, from no cointegration
(r = 0) to to increasing number of cointegrating vectors (see Figure ??). The
ˆ
eigenvalues of matrix Π is given in the second column. In the third column λtrace statistic is higher than the corresponding critical value at 5% significance for the first hypothesis. This means that we reject the null hypothesis of no cointegration.
115
Download free eBooks at bookboon.com
115

Multivariate Time Series Analysis

Financial Econometrics

However, we cannot reject the hypothesis that there is at most one cointegrating equation. On the basis of λmax statistics (the second panel) it is also possible to accept that there is only one cointegrating relationship. The following two panels provide estimates of matrices β and α respectively.
Note the warning on the top of the output window that saying that critical values assume no exogenous series. This means that we have to take into account that the critical values we are using might not be fully correct as we included exogenous dummy variables in the model. This may give as an explanation why we detected only one cointegrating equation instead of two which were expected. Another reason may be that the second relation based on the UIP condition involves changes of exchange rate rather than levels considered in the VAR model.

116
Download free eBooks at bookboon.com
116

Bibliography

Financial Econometrics

Bibliography
Bollerslev, T.: 1986, Generilized autoregressive conditional heterpscedasticity, Journal of Econometrics 31, 307–327.
Bollerslev, T., Engle, R. and Nelson, D.: 1994, ARCH Models, Vol. IV, Elsvier
Science, chapter Handbook in Econometrics, pp. 2961–3038.
Cuthbertson, K. and Nitzsche, D.: 2004, Quantitative Financial Economics: Stocks,
Bonds and Foreign Exchange, Jahn Wiley and Sons.
Dickey, D. and Fuller, W.: 1979, Distribution of the estimators for autoregressive time series with a unit root, Journal of the American Statistical Association
74, 427–431.
Dickey, D. and Fuller, W.: 1981, Likelihood ratio statistics for autoregressive time series with a unit root, Econometrica 49, 1057–1072.
Ding, Z., C. W. J. G. and (1993), R. F. E.: 1993, A long memory property of stock market returns and a new model, Journal of Empirical Finance 1, 83–106.
Durbin, J. and Watson, G.: 1950, Testing for serial correlation in least squares regression – I, Biometrica 37, 409–428.
Enders, W.: 2004, Applied Econometric Time Series, John Wiley and Sons.
Engle, R.: 1982, Autoregressive conditional heteroscedasticity with estimates of the variance of united kingdom inflation, Econometrica 50, 987–1007.
Engle, R. and Granger, C.: 1987, Cointegration and error correction: Representation, estimation and testing, Econometrics 55, 251–276.
Engle, R. and Lee, G.: 1999, A Long-Run and Short-Run Component Model of Stock
Return Volatility, Cointegration, Causality, and Forecasting, Oxford University
Press.
117

Download free eBooks at bookboon.com
117

Bibliography

Financial Econometrics

Engle, R., Lilien, D. and Robins, R.: 1987, Estimating time varying premia in the term structure: The ARCH-M model, Econmetrica 55, 591–407.
Fama, E. and French, K.: 1993, Common risk factors in the returns on stocks and bonds, Journal of Financial Economics 33, 3–56.
Fuller, W.: 1996, Introduction to Statistical Time Series, John Wiley and Sons,
New-York.
Granger, C.: 1969, Investigating causal relations by econometric models and cross spectral methods, Econometric 37, 424–438.
Greene, W.: 2000, Econometric Analysis, 5th edition edn, Prentice Hall, New Jersey.
Hamilton, J.: 1994, Time Series Analysis, Princeton University Press, New Jersey.
Harris, R.: 1995, Using Cointegration Analysis in Econometric Modelling, Prentice
Hall, London.
Hayashi, F.: 2000, Econometrics, Prinseton University Press.
Johansen, S. and Juselius, K.: 1990, Maximum likelihood estimation and inference on cointegration with application to the demand for money, Oxford Bulletin of
Economics and Statistics 52, 169–209.
Kwiatkowski, D., Phillips, P., Schmidt, P. and Shin, Y.: 1992, Testing the null hypothesis of stationarity against the alternative of a unit root, Journal of
Econometrics 54, 159–178.
Lutkepohl, H.: 1991, Introduction to Multiple Time Series Analysis, Springer,
Berlin.
MacKinnon, J.: 1996, Numerical distribution functions for unit root and cointegration tests, Journal of Applied Econometrics 11, 601–618.
Mills, T.: 1999, The Econometrics Modelling of Financial Time Series, Cambridge
University Press, Cambridge.
Nelson, D.: 1991, Conditional heteroskedasticity in asset returns: a new approach,
Econometrica 59(2), 347–370.
Osterwald-Lenum, M.: 1992, A note with quantiles of the asymptotic distribution of the maximum likelihood cointegration rank statistics, Oxford Bulletin of
Economics and Statistics 54, 461–472.
118
Download free eBooks at bookboon.com
118

Bibliography

Financial Econometrics

Phillips, P. and Ouliaris, S.: 1990, Asymptotic properties of residual based tests for cointegration, Econometrica 58, 73–93.
Phillips, P. and Perron, P.: 1988, Testing for a unit root in time series regression,
Biometrica 75, 335–346.
Reimars, H.-E.: 1992, Comparisons of tests formultivariate cointegration, Statistical
Papers 33, 335–359.
Reinsel, G. and Ahn, S.: 1992, Vector autoregression models with unit roots and reduced rank structure: Estimation, likelihood ratio test, and forecasting, Journal of Time Series Analysis 13, 353–375.
Said, S. and Dickey, D.: 1984, Testing for unit roots in autoregressive moving average models of unknown orders, Biometrica 71, 599–607.
Savin, N. and White, K.: 1977, The durbin-watson test for serial correlation with extreme sample sizes or many regressors, Econometrica 45, 1989–1996.
Tsay, R.: 2002, Analysis of Financial Time Series, John Wiley and Sons.
Verbeek, M.: 2008, A Guide to Modern Econometrics, John Wiley and Sons.
Zivot, E. and Wang, J.: 2006, Modeling Financial Time Series with S-PLUS,
Springer.

119

119

Similar Documents

Free Essay

Eview

...sử dụng Eviews 5.1 Phùng Thanh Bình CHƯƠNG 2 HƯỚNG DẪN SỬ DỤNG EVIEWS TRONG PHÂN TÍCH DỮ LIỆU VÀ HỒI QUI Chương này sẽ trình bày một số thủ tục cơ bản của phần mềm Eviews 5.1 để sinh viên có thể thực hành các bài tập thống kê và kinh tế lượng ở các chương sau. Do mục đích chính của ta là thực hành kinh tế lượng với Eviews, nên chương này chỉ giới hạn một số thao tác mà người nghiên cứu thường hay sử dụng, chứ không phải toàn bộ hướng dẫn chi tiết cách sử dụng Eviews. Tuy nhiên, để tiện lợi cho sinh viên tự nghiên cứu, chương này sẽ giới thiệu sơ qua chức năng trợ giúp trong Eviews để có thể tham khảo khi cần thiết. Một số nội dung được trình bày trong chương này, đặc biệt là các kiểm định, nhưng chúng sẽ được hướng dẫn một cách chi tiết hơn ở các chương liên quan. Để sinh viên có thể thực hành các bài tập và dự án nghiên cứu với Eviews, chương này sẽ nhằm vào các nội dung sau đây: • Eviews là gì? • Workfile là gì? • Trình bày dữ liệu trong Eviews • Đối tượng trong Eviews • Quản lý dữ liệu trong Eviews • Các phép toán và hàm số trong Eviews? • Phân tích dữ liệu chuỗi và nhóm • Xây dựng hàm kinh tế lượng trong Eviews • Kiểm định giả thiết mô hình hồi qui trong Eviews NHỮNG VẤN ĐỀ CƠ BẢN VỀ EVIEWS EVIEWS LÀ GÌ? Eviews1 cung cấp các công cụ phân tích dữ liệu phức tạp, hồi qui và dự báo chạy trên Windows. Với Eviews ta có thể nhanh chóng xây dựng một mối quan hệ kinh tế lượng từ dữ liệu có sẵn và sử dụng mối quan hệ này để dự báo các giá trị tương lai. Eviews có thể hữu...

Words: 9891 - Pages: 40

Premium Essay

Eviews Workshop

...EViews Workshop Program: MSc in Finance 2011-2012 Instructor: Dimitris Tsouknidis, MSc, MBA, PhD Email: dtsouknidis@gmail.com Course Description • Workshop 1 – Introduction, Regression Analysis, Multiple Regression Analysis • Workshop 2 – Issues with the Classical Linear Regression Model and Univariate Time-series Modeling in Finance • Workshop 3 – Multivariate Time-Series Modeling in Finance and Modeling Long-run Relationships in Finance MSc Finance - EViews Workshop 1 - 2012 2 Workshop 1 Introduction, Classical Linear Regression Analysis and Multiple Regression Analysis 19 January 2012 Agenda • • • • • • • Introduction to EViews Importing Data Loading and Saving Datasets Graphical and Statistical Analysis Regression Analysis Multiple Linear Regressions Case Studies – January Effect MSc Finance - EViews Workshop 1 - 2012 4 Introduction • EViews is a menu-driven econometric software. • Open EViews requires: – Start/All Programs/EViews 7 • EViews organizes data, graphs, output, etc. as objects. • Each of these objects can be copied, saved and/or cut-andpasted. • EViews is not case sensitive e.g. INDEX = index. • EViews is producing workfiles (.wf1). • You can import data from Microsoft Excel (.xls) and create workfiles (.wf1). MSc Finance - EViews Workshop 1 - 2012 5 Creating a Workfile • Click: File/New/Workfile. • You can select the type of your workfile (Dated – regular frequency, Balanced panel, Unstructured/Undated ), the frequency...

Words: 2127 - Pages: 9

Free Essay

Eviews Пособие

...МИНИСТЕРСТВО ОБРАЗОВАНИЯ РОССИЙСКОЙ ФЕДЕРАЦИИ НАЦИОНАЛЬНЫЙ ФОНД ПОДГОТОВКИ КАДРОВ ИННОВАЦИОННЫЙ ПРОЕКТ РАЗВИТИЯ ОБРАЗОВАНИЯ Программа «Совершенствование дисциплин в вузах» преподавания социально-экономических МИЭФ ГУ-ВШЭ (наименование вуза) Пособие для студентов по курсу «Анализ временных рядов» Москва 2003 Часть I. Руководство по эконометрическому пакету EViews Введение......................................................................................................... 3 1. Общие принципы работы в EViews ............................................................ 3 1.1. Создание рабочего файла EViews ........................................................ 4 Задания для самостоятельной работы......................................................... 9 1.2. Общая структура рабочего файла EViews ........................................... 9 Задания для самостоятельной работы....................................................... 12 2. Анализ одномерных временных рядов ..................................................... 12 2.1. Структура окна временного ряда ....................................................... 12 Задания для самостоятельной работы....................................................... 16 2.2 Построение графика временного ряда ................................................ 17 Задания для самостоятельной работы....................................................... 20 2.3. Описательные статистики временного ряда........................

Words: 17313 - Pages: 70

Free Essay

Eviews Commands

...Summary of important EViews-Commands Import of data from EXCEL: if the xlsx-format does not work, use File.xls Choice of sample period: Sample / @all @first @last 1990 2010 1981Q3 2005Q1 1960M1 2000M11 in command line e.g.: smpl @first 1990 Univariate statistics: Click series / View / Spreadsheet Graph Descriptive Statistics&Tests Correlogram data as numbers Graphics z.B. histogram, mean, etc. autocorrelationen Generation/Transformation of series: Generate / x = 0 generates a series with zeros Generate / pi = (pc – pc(-1))/pc(-1)*100 Generates the inflation rate in % based on prices pc Generate / x = log(y) taking logs Generate / dlx = dlog(x) dlx = log(x) – log(x(-1)) Growth rate in continuous time Generate / y = exp(x) exp(x) as command: series x=0 Trend variable (linear): Generate / t = @trend Standard normal distributed realizations: Generate / x = nrnd Lags, lagged variables, taking differences: Generate / x1 = x(-1) x1(t) = x(t-1), Lag 1 of x Generate / dx = d(x) dx(t) = x(t) – x(t-1) = (1-B)x(t) first difference Generate / d2x = d(x,2) d2x(t) = dx(t) – dx(t-1) = (1-B)^(2)x(t) taking first differences twice Generate / d12x = d(x,0,12) d12x(t) = x(t) - x(t-12) = [1-B^(12)]x(t) seasonal difference for monthly data Generate d12_1x = d(x,1,12) d12_1x(t) = (1-B)[1-B^(12)]x(t) Geneartion of dummy variables: seasonal dummies: s=1,2,3,... Generate / ds = @seas(s) as command: series ds = @seas(s) Generate / d1 = 0 and manually in View/Spreadsheet use Edit+/p-value for x of...

Words: 669 - Pages: 3

Free Essay

Introducion Al Eviews

...ivanca@arnet.com.ar . El producto E-views provee herramientas de regresión y predicción bajo Windows. Con E-views usted puede revelar una relación estadística desde sus datos y luego utilizar esta relación para predecir valores futuros de los mismos. Dentro de las áreas en donde E-views puede ser útil están: Predicción de ventas Análisis y predicción de costos. Análisis Financiero. Predicción macroeconómica. Simulación. Análisis científico de los datos y evaluación. E-views es una nueva versión del conjunto de herramientas para manipular series de tiempo originalmente desarrolladas en el software Time Series Processor para grandes computadoras. El predecesor inmediato de E-views fue el MicroTSP, lanzado por primera vez en 1981. Aunque Eviews fue desarrollado por economistas y la mayoría de sus usos están en la economía, no hay nada que haga limitar su utilidad a las series de tiempo económicas. Inclusive considerables proyectos de corte transversal pueden llevarse a cabo en E-views. El objeto básico dentro de E-views es la serie de tiempo. Cada serie posee un nombre, y usted puede realizar cualquier tipo de operación sobre todas las observaciones simplemente mencionando el nombre de la serie. E-views provee convenientes formas de visualización para ingresar las series desde el teclado o desde un archivo, para crear una serie a partir de otra ya existente, para mostrar o imprimir la serie, y para llevar a cabo análisis estadísticos sobre las relaciones entre las series. ...

Words: 8183 - Pages: 33

Free Essay

Introduce How to Use Eview

...BÀI GIẢNG 2: HƯỚNG DẪN SỬ DỤNG EVIEWS 6.0 ThS Phùng Thanh Bình BÀI GIẢNG 2 HƯỚNG DẪN SỬ DỤNG EVIEWS 6.0 MỤC TIÊU BÀI GIẢNG: 1. Eviews là gì? 2. Workfile là gì? 3. Trình bày dữ liệu trong Eviews? 4. Đối tượng trong Eviews 5. Quản lý dữ liệu trong Eviews 6. Các phép toán và hàm số gì trong Eviews 7. Các vấn đề cơ bản về phân tích dữ liệu chuỗi và nhóm 8. Xây dựng hàm kinh tế lượng trong Eviews 9. Kiểm định giả thiết của mô hình hồi qui trong Eviews ĐỐI TƯỢNG BÀI GIẢNG: 1. Tài liệu bài giảng cho sinh viên đại học 2. Tài liệu tham khảo ôn tập cho học viên cao học NHỮNG VẤN ĐỀ CƠ BẢN VỀ EVIEWS EVIEWS LÀ GÌ? Eviews1 cung cấp các công cụ phân tích dữ liệu phức tạp, hồi qui và dự báo chạy trên nền Windows. Với Eviews ta có thể nhanh chóng xây dựng một mối quan hệ thống kê từ dữ liệu có sẵn và sử dụng mối quan hệ này để dự báo các giá trị tương lai. Eviews có thể hữu ích trong nhiều lĩnh vực như phân tích và đánh giá dữ liệu khoa học, phân tích tài 1 Viết tắt của Econometrics Views 1 BÀI GIẢNG 2: HƯỚNG DẪN SỬ DỤNG EVIEWS 6.0 ThS Phùng Thanh Bình chính, dự báo kinh tế vĩ mô, mô phỏng, dự báo doanh số, và phân tích chi phí. Đặc biệt, Eviews là một phần mềm rất mạnh cho các nghiên cứu dữ liệu thời gian và dữ liệu chéo với cỡ mẫu lớn. Eviews đưa ra nhiều cách nhập dữ liệu rất thông dụng và dễ sử dụng như nhập từ bàn phím, từ các tập tin sẵn có dưới dạng Excel hay Text. Với Eviews, chúng ta có thể dễ dàng tạo ra các chuỗi mới từ các chuỗi hiện hành, hoặc mở rộng...

Words: 10459 - Pages: 42

Free Essay

Essay 2, Peer Eview

...ENGLISH 281 Draft Workshop Questions for Essay Two in Wikis Steps: 1. Post your draft to your appointed Wiki area by Sunday, April 5 by midnight. 2. Review drafts attached to your Wiki area and provide feedback using the below questions, pasting the answers in to the Wiki area and making it clear who the answers are for/whose draft you are commenting on and that you are the writer. For example, you could paste in something like the following: Susan, here are my thoughts/feedback on your draft posted so far: #1. [Provide feedback using the criteria below] #2 [Provide feedback using the criteria below] #3 on [Repeat above] You are expected to complete these steps for at least one draft posted to your group’s Wiki by Monday, April 6 by midnight for possible five points credit. Be sure to answer the “Specific Questions” below the first ten questions here depending on which essay prompt you are reading for a draft. 1. Does the author/student have all of the “front matter” needed in the draft? (i.e, Does it give an author tag with the title of the poem in quotes or name of book in italics and name of film in italics being worked with in the essay, for example and the author(s) name of text being discussed in the first one or two sentences of introduction)? If this is information is missing, let the author know here and also provide an example please of how it could be better. 2. Are the introductory sentences attention-grabbing? If they are...

Words: 1738 - Pages: 7

Premium Essay

Analysis of Nse Using Eviews

...Case Study: CNX Nifty Midcap Index Descriptive statistics A. Closing price 1. Normality Test – non-normal distribution 2. Stationarity test for Log returns – series is stationary Null Hypothesis: LOG_RETURNS has a unit root | | Exogenous: Constant | | | Lag Length: 0 (Automatic based on SIC, MAXLAG=23) | | | | | | | | | | | | | | t-Statistic |   Prob.* | | | | | | | | | | | Augmented Dickey-Fuller test statistic | -35.96681 |  0.0000 | Test critical values: | 1% level | | -3.434655 | | | 5% level | | -2.863328 | | | 10% level | | -2.567771 | | | | | | | | | | | | *MacKinnon (1996) one-sided p-values. | | | | | | | | | | | | Augmented Dickey-Fuller Test Equation | | Dependent Variable: D(LOG_RETURNS) | | Method: Least Squares | | | Date: 11/03/10 Time: 16:06 | | | Sample (adjusted): 1/04/2005 11/02/2010 | | Included observations: 1449 after adjustments | | | | | | | | | | | | Coefficient | Std. Error | t-Statistic | Prob.   | | | | | | | | | | | LOG_RETURNS(-1) | -0.944031 | 0.026247 | -35.96681 | 0.0000 | C | 0.000692 | 0.000484 | 1.429639 | 0.1530 | | | | | | | | | | | R-squared | 0.472016 |     Mean dependent var | 1.64E-07 | Adjusted R-squared | 0.471651 |     S.D. dependent var | 0.025333 | S.E. of regression | 0.018414 |     Akaike info criterion | -5.150009 | Sum squared resid | 0.490653...

Words: 2133 - Pages: 9

Premium Essay

Eview of Related Studies -- Inventory System

...Review of Related Studies -- Inventory System The following statements given are related to our study about the inventory system which is found very useful for the proponents in making the system.  "It is nearly impossible to overemphasize the importance of keeping inventory levels under control," Ronald Pachura wrote in an article for IIE Solutions. "Whether the problems incurred are caused by carrying too little or too much inventory, manufacturers need to become aware that inventory control is not just a materials management or warehouse department issue. The purchasing, receiving, engineering, manufacturing, and accounting departments all contribute to the accuracy of the inventory methods and records."  It is little wonder that business experts commonly cite inventory management as a vital element that can spell the difference between success and failure in today's keenly competitive business world. Writing in Production and Inventory Management Journal, Godwin Udo described telecommunications technology as a critical organizational asset that can help a company realize important competitive gains in the area of inventory management. According to Udo, companies that make good use of this technology are far better equipped to succeed than those who rely on outdated or unwieldy methods of inventory control. Automation can draidatically affect all phases of inventory management, including counting and monitoring of inventory items; recording and retrieval of item storage...

Words: 290 - Pages: 2

Premium Essay

Essay

...I nternational eview of anagement and usiness esearch ol. 2 ssue.1 Impact of Organizational Culture on Employee Performance ALHARBI MOHAMMAD AWADH University Technology Malaysia International Business School, Malaysia E-mail: alharbimohamd@gmail.com ALYAHYA, MOHAMMED SAAD University Utara Malaysia College of Business Malaysia. Email: msy330@hotmail.com Abstract Aim of the study: The relationship between organizational culture and performance has been study and a clear link between them has been identified by certain researcher’s research. The main aim of research article is to identify and measure strong relationship between performance and organizational culture. Methodology: Literature review is adopted as methodology to assess the culture of an organization impacts upon process, employees and systems. Findings: Certain dimensions of culture have been identified so far and research shows that value and norms of an organization were based upon employee relationship. The goal of an organization is to increase level of performance by designing strategies. The performance management system has been measured by balance scorecard and by understanding nature and ability of system culture of an organization have been identified. Recommendation: The strong culture of an organization based upon managers and leaders help in improving level of performance. Managers relate organization performance and culture to each other as they help in providing competitive...

Words: 3184 - Pages: 13

Premium Essay

Sdffffffffffffff

...t-statistic. Here are the various cases of the test equation: a. When the time series is flat (i.e. doesn’t have a trend) and potentially slowturning around zero, use the following test equation: Δz t = θz t −1 + α 1 Δz t −1 + α 2 Δz t − 2 + L + α p Δz t − p + a t where the number of augmenting lags (p) is determined by minimizing the Schwartz Bayesian information criterion or minimizing the Akaike information criterion or lags are dropped until the last lag is statistically significant. EVIEWS allows all of these options for you to choose from. Notice that this test equation does not have an intercept term or a time trend. What you want to use for your test is the t-statistic associated with the Ordinary least squares estimate of θ . This is called the Dickey-Fuller tstatistic. Unfortunately, the Dickey-Fuller t-statistic does not follow a standard t-distribution as the sampling distribution of this test statistic is skewed to the left with a long, left-hand-tail. EVIEWS will give you the correct critical values for the test, however. Notice that the test is left-tailed. The null hypothesis of the Augmented Dickey-Fuller t-test is H0 :θ = 0 (i.e. the data needs to be differenced to make it stationary) versus the alternative hypothesis of H1 : θ < 0 b. (i.e. the data is stationary and doesn’t need to be differenced) When the time series is flat and potentially slow-turning around a non-zero value, use the following test equation: Δz t = α...

Words: 735 - Pages: 3

Premium Essay

Econometrics Project 1

...Introduction The purpose of the project was to see if using futures contracts to hedge can reduce exposure to market risk over a period of time. This project covered both stock portfolios and bond portfolios. To illustrate this, the method of linear regression and least squares was used. We used linear regression to regress the spot rate against the futures contract return. To complete this project both EViews and Microsoft Excel was used. Summary of Points Stock Regression 2008-2009 Around 96% of the stock portfolio returns can be explained. This was calculated by finding the variance proportion, r2 in EViews. The high percentage suggests that our model is a strong fit for the data that was analyzed. We were also able to show that our estimated beta was reliably different than 0 and reliably different than 1. This was done through two-sided tests using a 95% significance level. The tcrit value was found using the excel function tinv() with 497 degrees of freedom. Testing for B=0, the t-statistic was 110.087, with the tcrit value being 1.964 this was a clear indication to reject the null because 110.087 is not in the range of -1.964 to 1.964. Testing for B=1, the t-statistic was -3.37853, with the tcrit value being 1.964 this was also a clear indication to reject the null because -3.37853 is not in the range of -1.964 to 1.964. After finding the optimal hedge ratio we calculated the dollar position for the futures market hedge to be $9,702,250. By using...

Words: 714 - Pages: 3

Premium Essay

Knowledge Sharing

...A REVOLUTION IN Donald M. Norris is President, Strategic Initiatives, Inc. Jon Mason is Executive Consultant, education.au limited, and Assistant Director, Educational Technology Standards Australia. Robby Robson is President and Senior Partner, Eduworks Corporation, and chair of the IEEE Learning Technology Standards Committee. Paul Lefrere is Executive Director E-learning, Microsoft EMEA, and Professor of E-learning, University of Tampere, Finland. Geoff Collier is CFO and Senior Partner, Eduworks Corporation. KNOWLEDGE SHARING By Donald M. Norris, Jon Mason, Robby Robson, Paul Lefrere, and Geoff Collier 14 EDUCAUSE r eview September/October 2003 © 2003 Donald M. Norris, Jon Mason, Robby Robson, Paul Lefrere, and Geoff Collier Photo by Garry Landsman, © 2003 September/October 2003 EDUCAUSE r eview 15 E-knowledge finds expression in many shapes and forms in a profoundly networked world. It is not just a digitized collection of knowledge. E-knowledge consists of knowledge objects and knowledge flows that combine content,...

Words: 6533 - Pages: 27

Premium Essay

Hypothsis Test

...Hypothesis Testing and EViews p-values: Suppose that we want to test a null hypothesis about a single parameter using its estimated value (for example a mean or a regression coefficient). We can do so using a t-test. To begin, suppose that the parameter to be estimated is β. We must first specify a null hypothesis and an alternative hypothesis. 2 tail test: For a two tailed test, we want to test whether β is a particular value or not. We first set the value of β that we want to test. We’ll call this β0 to indicate that this will be the value of β under the null hypothesis. In a two tail test, the null and alternative hypotheses are: H0 : β = β 0 HA : β = β0 ˆ We proceed by estimating β. We denote the estimated value as β. This could for example be a sample mean estimate of the population mean, a least squared estimate of a regression coefficient, or a maximum likelihood estimate of a model coefficient, ˆ depending on the context. The estimate β is usually accompanied by a standard error ˆ to indicate how precisely it is estimated. We denote this standard error as se(β). This ˆ is a random variable with a sampling distribution. It will have reflects the fact the β different values in different samples. We can then form the following test statistic by computing the standardised statistic ˆ whereby we subtract the hypothesisized value β0 from the estimate β and divide by its standard error: t-stat = ˆ β − β0 ˆ se(β) ˆ Again, this test statistic is a random variable since it depends...

Words: 1819 - Pages: 8

Premium Essay

Ningning

...whether there is data available that will allow you to answer your question. It is a good idea to write down your ideal data set that would allow you to address your topic. If you find that the available data is not even close to what you had originally desired, you might want to change your topic. Also, remember that knowing the location of your data – website, reference book, etc – is not the same as having your data available to use. It may take a LONG time to get the data in a format that EVIEWS can read. Do not leave this till the last minute. For most data, I enter the data into Excel first. I save the Excel sheet in the oldest version, namely MS Excel Worksheet 2.1 . The reason is that format can be read by most programs whereas newer formats may or may not be read. Eviews easily reads an Excel sheet 2.1 version. You should use the first row to label your columns (variables). Be sure to follow the naming conventions in Eviews and do not use 'C' or 'RESIDUALS'. Eviews can only use numeric data. A warning for time series analysis - In order to find interesting results, you need variation in your data. For example, it would be difficult to find the effect of defense spending on American manufacturing industries if...

Words: 2375 - Pages: 10