Econ 493 A1 - Fall 2019
Homework 4
Assignment Information
This assignment is due on Monday November 18 at 11:59 am.
Submit the assignment in the locked box in the Department of Economics General Office
(Tory 8-14). Note that the General Office is CLOSED daily from 12-1 pm and after 4:00 pm.
Late assignments will receive NO MARKS.
Answers to computing exercises must include R commands and output files when applicable.
All answers must be transcribed to your written answers which must be separate from the R
printout.
Total marks = 50 (5 questions).
Exercise 1
Electricity consumption is often modelled as a function of temperature. Temperature is
measured by daily heating degrees and cooling degrees. Heating degrees is 18◦C minus the
average daily temperature when the daily average is below 18◦C; otherwise it is zero. This
provides a measure of our need to heat ourselves as temperature falls. Cooling degrees
measures our need to cool ourselves as the temperature rises. It is defined as the average
代做Econ 493作业、data留学生作业代写
daily temperature minus 18◦C when the daily average is above 18◦C; otherwise it is zero.
Let yt denote the monthly total of kilowatt-hours of electricity used, let x1,t denote the
monthly total of heating degrees, and let x2,t denote the monthly total of cooling degrees.
An analyst fits the following model to a set of such data:
a. What sort of ARIMA model is identified for ηt?
b. The estimated coefficients of β1 and β2 are found to be greater than zero. Explain what
the estimates of β1 and β2 tell us about electricity consumption.
c. Describe how this model could be used to forecast electricity demand for the next 12
months.
d. Explain why the ηt term should be modelled with an ARIMA model rather than
modeling the data using a standard regression package. In your discussion, comment on
the properties of the estimates, the validity of the standard regression results, and the
importance of the ηt model in producing forecasts.
1
Exercise 2
Given an initial value for y0, re-write each yt
in terms of y0 and past innovations (that is, εi
for i = 0, . . . , t). Also, find the h-step-ahead forecast for h = 1, 2.
a. yt = yt−1 + εt + 0.5εt−1
b. yt = 1.1yt−1 + εt
c. yt = yt−1 + 1 + εt
d. yt = yt−1 + t + εt
Exercise 3 (R)
The file us_macro_quarterly.csv contains quarterly data on several macroeconomic series
for the United States. The variable P CEP is the price index for personal consumption
expenditures from the US National Income and Product Accounts. In this exercise you will
construct forecasting models for the rate of inflation, based on P CEP. For this analysis, use
the sample period 1963Q1 to 2012Q4.
a. Compute the inflation rate, inflt = 400 × [log(P CEPt) − log(P CEPt−1)]. What are
the units of infl?
b. Use R to plot the inflation rate series (infl) and the ACF. Does the series appear to be
stationary? Explain.
c. Use R to plot the change in the inflation rate series (infl0
) and the ACF. Does the
differenced series appear to be stationary? Explain.
d. Use the ADF test to determine d.
e. Compute and plot the one-step-ahead quarterly forecasts of the inflation rate for the
pseudo out-of-sample period 2003Q1 to 2012Q4 (40 quarters) using the following models:
(i) an ARIMA(2,0,0) and (ii) and ARIMA(2,1,0). Compare your results in terms of the
RMSE.
f. Are the pseudo out-of-sample forecasts biased? That is, do the forecast errors have a
non-zero mean?
Exercise 4 (R)
Consider the spurious regression problem with time series data. The file inflation.csv
contains 39 annual observations of the following variables (by columns): - Year: 1971-2009 -
Deaths: Total number of deaths, Canada - CPI: Consumer Price Index, Canada
a. Use the CPI series to compute the annual inflation rate, inflt = 100 × [log(CP It) −
log(CP It−1)] for the sample 1972–2009. Plot the time series.
b. Obtain the total number of deaths in Canada per 1000 people for the sample 1972–2009
(that is, divide the data by 1000). Plot the time series.
c. Use OLS to estimate the equation inflt = β0 + β1deadt + εt
. Is deaths significant at
the 5% level? What is the sign of the slope coefficient?
d. Relate your results in (c) to the spurious regression problem.
2
e. Use OLS to estimate the equation infl0
t = β0 + β1dead0
t + εt
. Is deaths significant at
the 5% level? What is the sign of the slope coefficient?
f. Use OLS to estimate the equation inflt = β0+β1deadt+β2time+εt
. Is deaths significant
at the 5% level? What is the sign of the slope coefficient?
Exercise 5 (R)
The file quarterly.csv contains the series of quarterly industrial production and the consumer’s
price index (CPI) for the US for the quarters 1960:Q1 to 2012:Q4.
a. Create the log change in the index of industrial production (indprod) as
lip0 = log(indprodt) − log(indprodt−1) and the inflation rate as inflt = log(CP It) −
log(CP It−1).
b. Determine if lip0 and inflt are stationary?
c. Estimate the bivariate VAR using three lags of each variable and a constant. Verify
that the three-lag specification is selected by the BIC, whereas the AIC selects five lags.
d. Perform the Granger causality tests. Verify that the F-statistic for the test that inflation
Granger-causes industrial production is 4.82 (with a significance level of 0.003) and that
the F-statistic for the test that industrial production Granger-causes inflation is 5.1050
(withh a significance level of 0.002).

因为专业,所以值得信赖。如有需要,请加QQ:99515681 或邮箱:99515681@qq.com

微信:codehelp

Econ 493 A1 - Fall 2019的更多相关文章

  1. CMU15445 (Fall 2019) 之 Project#1 - Buffer Pool 详解

    前言 这个实验有两个任务:时钟替换算法和缓冲池管理器,分别对应 ClockReplacer 和 BufferPoolManager 类,BufferPoolManager 会用 ClockReplac ...

  2. CMU15445 (Fall 2019) 之 Project#4 - Logging & Recovery 详解

    前言 这是 Fall 2019 的最后一个实验,要求我们实现预写式日志.系统恢复和存档点功能,这三个功能分别对应三个类 LogManager.LogRecovery 和 CheckpointManag ...

  3. CMU15445 (Fall 2019) 之 Project#2 - Hash Table 详解

    前言 该实验要求实现一个基于线性探测法的哈希表,但是与直接放在内存中的哈希表不同的是,该实验假设哈希表非常大,无法整个放入内存中,因此需要将哈希表进行分割,将多个键值对放在一个 Page 中,然后搭配 ...

  4. CMU15445 (Fall 2019) 之 Project#3 - Query Execution 详解

    前言 经过前面两个实验的铺垫,终于到了给数据库系统添加执行查询计划功能的时候了.给定一条 SQL 语句,我们可以将其中的操作符组织为一棵树,树中的每一个父节点都能从子节点获取 tuple 并处理成操作 ...

  5. PSTAT 115 Homework4 课业解析

    PSTAT 115 Homework4 课业解析 题意: 蒙特卡洛采样之拒绝采样 解析: 给定一个概率分布p(z)=p~(z)/Zp,p~(z)已知,Zp为归一化常数,为未知数.对该分布进行拒绝采样, ...

  6. Computing Science CMPT 361

    Computing Science CMPT 361 Fall 2019Assignment #3Due date: November 27th at 11:59 pm.Ray TracingYou ...

  7. GrapeCity Documents for Excel 文档API组件 V2.2 新特性介绍

    GrapeCity Documents for Excel 文档API组件 V2.2 正式发布,本次新版本包含诸多重量级产品功能,如:将带有形状的电子表格导出为 PDF.控制分页和电子表格内容.将Ex ...

  8. MIT6.S081/6.828 实验1:Lab Unix Utilities

    Mit6.828/6.S081 fall 2019的Lab1是Unix utilities,主要内容为利用xv6的系统调用实现sleep.pingpong.primes.find和xargs等工具.本 ...

  9. 家里蹲大学数学杂志 Charleton University Mathematics Journal 官方目录[共七卷493期,6055页]

    家里蹲大学数学杂志[官方网站]从由赣南师范大学张祖锦老师于2010年创刊;每年一卷, 自己有空则出版, 没空则搁置, 所以一卷有多期.本杂志至2016年12月31日共7卷493期, 6055页.既然做 ...

随机推荐

  1. java基于NIO的分散读取文件,然后统一聚合后写入文件

    分散读取:对于一个文件,可以分散的读取数据,可以快速的读取,好比多个线程在分段同时读取: 聚合写入:为了提高效率,一般读取到的数据都是分散的,要快速写入,就需要把分散的数据聚集在一起,然后一块写入到文 ...

  2. .NET Core RabbitMQ探索(2)——RabbitMQ的Exchange

    实际上,RabbitMQ的生产者并不会直接把消息发送给队列,甚至生产者都不知道消息是否会被发送给一个队列.对于生产者而言,它们只能把消息发送到Exchange,一个Exchange所完成的工作相当简单 ...

  3. Python简单的get和post请求

    1.json 模块提供了一种很简单的方式来编码和解码JSON数据. 其中两个主要的函数是 json.dumps() 和 json.loads() , 要比其他序列化函数库如pickle的接口少得多. ...

  4. STP:生成树协议解决网络冗余问题

    STP(Spanning Tree Protocol)是生成树协议的英文缩写,可应用于计算机网络中树形拓扑结构建立,主要作用是防止网桥网络中的冗余链路形成环路工作.但某些特定因素会导致STP失败,要排 ...

  5. Odoo学习笔记一:odoo初探

    转载请注明原文地址:https://www.cnblogs.com/ygj0930/p/11189194.html 一:Odoo架构 1:数据库服务器层:postgreSQL数据库服务器,用于存储所有 ...

  6. Python从零开始——集合Set

    一:Python集合知识概览 二:Python的特性.格式.以及各序列结构对比 三:Python集合set的创建 四:集合常用操作之——添加元素 五:集合常见操作之——删除元素 六:集合常见操作之—— ...

  7. debian apt-get 代理

    一:在 /etc/apt/目录下建立 apt.conf 文件增加如下 Acquire::http::Proxy "http://proxyxxxxxxx:port"; 注意格式:最 ...

  8. 感知哈希算法——Python实现【转】

    转自:https://blog.csdn.net/m_buddy/article/details/78887248 版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原 ...

  9. jenkins使用小技巧:pom.xml文件里的版本随着每次发布变化怎么办?

    针对这个问题,构建方法不变, 变化在动态去获取每次打出来的包名, 比如说,本次打出来的报名mypackage-1.0.3-SNAPSHOT.jar 那么,先进入target目录 #先进入target目 ...

  10. mpvue小程序加载不出图片 Failed to load local image resource /images/xx.png

    解决方法: 直接写 /static/img/xx.png(一定要从 "/static" 开始,不要写成 "../../static" ,当然static里面也可 ...