Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

Longley

Longley's Regression Data


Description

US macroeconomic time series, 1947–1962.

Usage

data("Longley")

Format

An annual multiple time series from 1947 to 1962 with 4 variables.

employment

Number of people employed (in 1000s).

price

GNP deflator.

gnp

Gross national product.

armedforces

Number of people in the armed forces.

Details

An extended version of this data set, formatted as a "data.frame" is available as longley in base R.

Source

Online complements to Greene (2003). Table F4.2.

References

Greene, W.H. (2003). Econometric Analysis, 5th edition. Upper Saddle River, NJ: Prentice Hall.

Longley, J.W. (1967). An Appraisal of Least-Squares Programs from the Point of View of the User. Journal of the American Statistical Association, 62, 819–841.

See Also

Examples

data("Longley")
library("dynlm")

## Example 4.6 in Greene (2003)
fm1 <- dynlm(employment ~ time(employment) + price + gnp + armedforces,
  data = Longley)
fm2 <- update(fm1, end = 1961)
cbind(coef(fm2), coef(fm1))

## Figure 4.3 in Greene (2003)
plot(rstandard(fm2), type = "b", ylim = c(-3, 3))
abline(h = c(-2, 2), lty = 2)

AER

Applied Econometrics with R

v1.2-10
GPL-2 | GPL-3
Authors
Christian Kleiber [aut] (<https://orcid.org/0000-0002-6781-4733>), Achim Zeileis [aut, cre] (<https://orcid.org/0000-0003-0918-3766>)
Initial release
2022-06-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.