Title: Functions and Datasets for "Bayesian Methods: A Social and Behavioral Sciences Approach"
Version: 1.0.3
Author: Jonathan Homola, Danielle Korman, Jacob Metz, Miguel Pereira, Mauricio Vela, and Jeff Gill <jgill5402@mac.com>
Maintainer: Jeff Gill <jgill5402@mac.com>
Description: Functions and datasets for Jeff Gill: "Bayesian Methods: A Social and Behavioral Sciences Approach". First, Second, and Third Edition. Published by Chapman and Hall/CRC (2002, 2007, 2014) <doi:10.1201/b17888>.
Depends: R (≥ 3.0.1)
Imports: MASS, mice
Suggests: coda, nnet
License: GPL-2 | GPL-3 [expanded from: GPL (≥ 2)]
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.1.1
Packaged: 2022-10-14 05:13:08 UTC; selimyaman
NeedsCompilation: no
Repository: CRAN
Date/Publication: 2022-10-14 11:25:17 UTC

DA_cwp

Description

Data on ancient Chinese wars

Details

The variables included in the dataset are:


actuarial

Description

actuarial claims data for three groups of insurance policyholders p. 449

Usage

data(actuarial)

Format

dataset with 5 observations of 7 variables

Details

The variables included in the dataset are:

Source

Scollnik, D. P. M. (2001). Actuarial Modeling with MCMC and BUGS. North American Actuarial Journal 5, 95-124.


adam.jags

Description

data from Differences in the Validity of Self-Reported Drug Use Across Five Factors in Indianapolis, Fort Lauderdale, Phoenix, and Dallas, 1994 (ICPSR Study Number 2706, Rosay and Herz (2000), from the Arrestee Drug Abuse Monitoring (ADAM) Program/Drug Use Forecasting, ICPSR Study Number 2826. The original purpose of the study was to understand the accuracy of self-reported drug use, which is a difficult problem for obvious reasons.

The variables included in the dataset are:

Usage

data(adam.jags)

afghan.deaths

Description

NATO Fatalities in Afghanistan, 10/01 to 1/07. see page 350

Usage

data(afghan.deaths)

Format

52 monthly periods, listed by rows


africa

Description

African Coups Data, pp.562-564

Usage

data(africa)

Format

data frame with 33 observations of different African countries' military coups with 7 explanatory variables

Details

The variables included in the dataset are:

Source

Bratton, M. and Van De Walle, N. (1994). Neopatrimonial Regimes and Political Transitions in Africa. World Politics 46, 453-489.


asap.data.list

Description

The American State Administrator's Project (ASAP) survey asks administrators about the influence of a variety of external political actors including "clientele groups" in their agencies., see page 395.

The variables included in the dataset are:

Usage

data(asap.data.list)

Baldus Dataset

Description

Data from Baldus Study on death sentences in Georgia (Exercise 14.2, p. 521). To use the data in JAGS or WinBugs, see baldus.jags and balfus.winbugs, respectively.

Usage

data(baldus)

Details

The variables included in the dataset are:

Source

Baldus, D. C., Pulaski, C., & Woodworth, G. (1983). Comparative review of death sentences: An empirical study of the Georgia experience. The Journal of Criminal Law and Criminology (1973-), 74(3), 661-753.

See Also

baldus.jags baldus.winbugs


bcp

Description

Implementation of bcp function, see pages 362-363 (2nd Edition).

Usage

bcp(theta.matrix, y, a, b, g, d)

Arguments

theta.matrix

theta.matrix

y

Counts of Coal Mining Disasters

a

Alpha Value in the lambda Prior

b

Beta Value in the lambda Prior

g

Gamma Value in the phi Prior

d

Delta Value in the phi Prior

Author(s)

Jeff Gill

Examples

## Not run: 
bcp(theta.matrix,y,a,b,g,d)

## End(Not run)

biv.norm.post

Description

A function to calculate posterior quantities of the bivariate normal. See page 94.

Usage

biv.norm.post(data.mat,alpha,beta,m,n0=5)

Arguments

data.mat

A matrix with two columns of normally distributed data

alpha

Wishart first (scalar) parameter

beta

Wishart second (matrix) parameter

m

prior mean for mu

n0

prior confidence parameter

Value

Returns

mu2

posterior mean, dimension 1

sig1

posterior mean, dimension 2

sig2

posterior variance, dimension 1

rho

posterior variance, dimension 2

Author(s)

Jeff Gill

Examples


 rwishart <- function(df, p = nrow(SqrtSigma), SqrtSigma = diag(p))  { 
 if((Ident <- missing(SqrtSigma)) && missing(p)) stop("either p or SqrtSigma must be specified") 
 Z <- matrix(0, p, p) 
 diag(Z) <- sqrt(rchisq(p, df:(df-p+1))) 
 if(p > 1) { 
   pseq <- 1:(p-1) 
   Z[rep(p*pseq, pseq) + unlist(lapply(pseq, seq))] <- rnorm(p*(p-1)/2) 
 } 
 if(Ident) crossprod(Z) 
 else crossprod(Z %*% SqrtSigma)
 }
  
  data.n10 <- rmultinorm(10, c(1,3), matrix(c(1.0,0.7,0.7,3.0),2,2))
  rep.mat <- NULL; reps <- 1000
  for (i in 1:reps){
    rep.mat <- rbind(rep.mat, biv.norm.post(data.n10,3, matrix(c(10,5,5,10),2,2),c(2,2)))
  }
  round(normal.posterior.summary(rep.mat),3)
    

cabinet.duration

Description

Cabinet duration (constitutional inter-election period) for eleven Western European countries from 1945 to 1980, page 65

Usage

cabinet.duration

Format

cabinet duration of 11 countries

Details

The variables included in the dataset are:

Note

Row names indicate country.

References

Browne, E. C., Frendreis, J. P., and Gleiber, D. W. (1986). The Process of Cabinet Dissolution: An Exponential Model of Duration and Stability in Western Democracies. American Journal of Political Science 30, 628-650.


child

Description

Child Support Collection Policies from 50 states from 1982-1991. See page 166

Usage

child

Format

observations of 8 variables for 50 states

Details

The variables included in the dataset are:

Source

Meier, K.J. and Keisler, L.R. (1996). Public Administration as a Science of the Artificial: A Method for Prescription, Public Administration Review 56, 459-466.


china.wars

Description

Modeling code for the example of ancient Chinese wars. See page 163-165

Usage

china.wars()

Author(s)

Jeff Gill

Source

Claudio Cioffi-Revilla and David Lai, 2001,
"Chinese Warfare and Politics in the Ancient East Asian International System",
Download from <doi:10.1080/03050620108434971>
Henry A. Murray Research Archive
Center for International Relations, Department of Political Science, University of Colorado, Boulder, USA


coal.mining.disasters

Description

A vector of British Coal Mining Disasters, see page 549-550

Usage

coal.mining.disasters

Format

vector of length 111

Source

Lynn, R. and Vanhanen, T. (2001). National IQ and Economic Development. Mankind Quarterly LXI, 415-437.


contracep

Description

Contraception Data by country. See page 446

Usage

data(contracep)

Format

4 variables for 15 countries

Details

The variables included in the dataset are:

Source

Wong, G. Y. and Mason, W. M. (1985). The Hierarchical Logistic Regression Model for Multilevel Analysis. Journal of the American Statistical Association 80, 513-524.


dmultinorm

Description

dmultinorm function, see page 376.

Usage

dmultinorm(xval,yval,mu.vector,sigma.matrix)

Arguments

xval

Vector of X Random Variables

yval

Vector of Y Random Variables

mu.vector

Mean Vector

sigma.matrix

Matrix of Standard Deviations

Author(s)

Jeff Gill


dp

Description

Death Penalty Data, See Page 142.

Usage

data(dp)

Format

7 variables for 17 states

Details

The variables included in the dataset are:

Source

Norrander, B. (2000). The Multi-Layered Impact of Public Opinion on Capital Punishment Implementation in the American States. Political Research Quarterly 53, 771-793.


durations.hpd

Description

Simple HPD calculator from Chapter 2 (page 51, 2nd Edition).

Usage

durations.hpd(support,fn.eval,start,stop,target=0.90,tol=0.01)

Arguments

support

x-axis values

fn.eval

function values at x-axis points

start

starting point in the vectors

stop

stoppng point in the vectors

target

Desired X Level

tol

Tolerance for round-off

Author(s)

Jeff Gill

Examples

## Not run: 
  get("cabinet.duration")
  ruler <- seq(0.45,0.75,length=10000)
  g.vals <- round(dgamma(ruler,shape=sum(cabinet.duration$N), 
                  rate=sum(cabinet.duration$N*cabinet.duration$dur)),2)
  start.point  <- 1000; stop.point <- length(g.vals)
  durations.hpd(ruler,g.vals,start.point,stop.point)

## End(Not run)


elicspend

Description

Eliciting expected campaign spending data. Eight campaign experts are queried for quantiles at levels m = [0.1, 0.5, 0.9], and they provide the following values reflecting the national range of expected total intake by Senate candidates (in thousands). See page 120

Usage

data(elicspend)

ethnic.immigration

Description

1990-1993 W.Europe Ethnic/Minority Populations. see page 280.

Usage

data(ethnic.immigration)

Format

total number of ethnic immigrants living in Western Europe from 22 countries

Details

The variables included in the dataset are:

Source

Peach, C. (1997). Postwar Migration to Europe: Reflux, Influx, Refuge. Social Science Quarterly 78, 269-283.


executions

Description

Execution data.

The variables included in the dataset are:

Usage

data(executions)

Format

explanatory variables for 17 states


Campaign fundraisign elicitations

Description

Fabricated data on campaign fundraising elicitations. See page 120

Usage

experts(q1,q2,q3)

Arguments

q1

the 0.1 quantile

q2

the 0.5 quantile

q3

the 0.9 quantile


expo.gibbs

Description

Simple Gibbs sampler demonstration on conditional exponentials from Chapter 1 (pages 25-27).

Usage

expo.gibbs(B,k,m)

Arguments

B

an upper bound

k

length of the subchains

m

number of iterations

Author(s)

Jeff Gill


expo.metrop

Description

Simple Metropolis algorithm demonstration using a bivariate exponential target from Chapter 1 (pages 27-30).

Usage

expo.metrop(m,x,y,L1,L2,L,B)

Arguments

m

number of iterations

x

starting point for the x vector

y

starting point for the y vector

L1

event intensity for the x dimension

L2

event intensity for the y dimension

L

shared event intensity

B

upper bound

Author(s)

Jeff Gill

Examples


expo.metrop(m=5000, x=0.5, y=0.5, L1=0.5, L2=0.1, L=0.01, B=8)


fdr

Description

FDR election data. See page 576

The variables included in the dataset are:

Usage

data(fdr)

hanjack

Description

1964 presidential election data. See page 221

Usage

hanjack(N,F,L,W,K,IND,DEM,WR,WD,SD)

Arguments

N

number of cases in the group

F

Observed cell proportion voting for Johnson

L

log-ratio of this proportion, see p. 246

W

collects the inverse of the diagonal of the matrix for the group-weighting from $[N_iP_i(1-P_i)]$

K

constant

IND

indifference to the election

DEM

stated preference for Democratic party issues

WR

Weak Republican

WD

Weak Democrat

SD

Strong Democrat

References

Hanushek, E. A. and Jackson, J. E. (1977). Statistical Methods for Social Scientists San Diego, Academic Press


hit.run

Description

Implementation of hit.run algorithm, p. 361.

Usage

hit.run(theta.mat,reps,I.mat)

Arguments

theta.mat

theta.mat

reps

reps

I.mat

I.mat

Author(s)

Jeff Gill

Examples

## Not run: 
#code to implement graph on p. 362, see page 376.

num.sims <- 10000
Sig.mat <- matrix(c(1.0,0.95,0.95,1.0),2,2)
walks<-rbind(c(-3,-3),matrix(NA,nrow=(num.sims-1),ncol=2))
walks <- hit.run(walks,num.sims,Sig.mat)
z.grid <- outer(seq(-3,3,length=100),seq(-3,3,length=100),
                FUN=dmultinorm,c(0,0),Sig.mat)
contour(seq(-3,3,length=100),seq(-3,3,length=100),z.grid,
        levels=c(0.05,0.1,0.2))
points(walks[5001:num.sims,],pch=".")

iq data frame

Description

IQ data for 80 countries. See pages 85-87

Usage

data(iq)

Source

Lynn, R. and Vanhanen, T. (2001). National IQ and Economic Development. Mankind Quarterly LXI, 415-437.

Examples

## Not run: 
{
data(iq)
n <- length(iq[1,])
t.iq <- (iq[1,]-mean(as.numeric(iq)))/(sd(iq[1,])/sqrt(n))
r.t <- (rt(100000, n-1)*(sd(iq)/sqrt(n))) + mean(as.numeric(iq))
quantile(r.t,c(0.01,0.10,0.25,0.5,0.75,0.90,0.99))
r.sigma.sq <- 1/rgamma(100000,shape=(n-2)/2, rate=var(as.numeric(iq))*(n-1)/2)
quantile(sqrt(r.sigma.sq), c(0.01,0.10,0.25,0.5,0.75,0.90,0.99))
}
## End(Not run)

italy.parties

Description

Italian Parties Data. Vote share of Italian parties from 1948-1983. See page 370-371.

Usage

data(italy.parties)

lunatics

Description

An 1854 study on mental health in the fourteen counties of Massachusetts yields data on 14 cases. This study was performed by Edward Jarvis (then president of the American Statistical Association)

The variables included in the dataset are:

Usage

data(lunatics)

Marriage Rates in Italy

Description

Italian Marriage Rates. See page 430

Usage

data(marriage.rates)

Format

a vector containing 16 numbers

Source

Columbo, B. (1952). Preliminary Analysis of Recent Demographic Trends in Italy. Population Index 18, 265-279.


metropolis

Description

Implementation of metropolis function, p. 359.

Usage

metropolis(theta.matrix,reps,I.mat)

Arguments

theta.matrix

theta.matrix

reps

reps

I.mat

I.mat

Author(s)

Jeff Gill


militarydf

Description

A dataset of two variables. The proportional changes in military personnel for the named countries. See page 483-484

The variables included in the dataset are:

Usage

data(militarydf)

Format

a data frame with 35 observations of years from 1949 to 1983 with 10 explanatory variables

Source

Faber, J. (1989). Annual Data on Nine Economic and Military Characteristics of 78 Nations (SIRE NATDAT), 1948-1983. Ann Arbor: Inter-University Consortium for Political and Social Research and Amsterdam, and Amsterdam, the Netherlands: Europa Institute, Steinmetz Archive.


nc.sub.dat

Description

North Carolina county level health data from the 2000 U.S. census and North Carolina public records, see page 78.

The variables included in the dataset are:

Usage

nc.sub.dat

Format

data frame with 100 observations of different counties in North Carolina with 3 explanatory variables

Source

data from 2000 US census and North Carolina Division of Public Health, Women's and Children's Health Section in Conjunction with State Center for Health Statistics


norm.known.var

Description

A function to calculate posterior quanties for a normal-normal model with known variance (pages 70-72). It produces the posterior mean, variance, and 95% credible interval for user-specified prior.

Usage

norm.known.var(data.vec,pop.var,prior.mean,prior.var)

Arguments

data.vec

a vector of assumed normally distributed data

pop.var

known population variance

prior.mean

mean of specified prior distribution for mu

prior.var

variance of specified prior distribution for mu

Author(s)

Jeff Gill


normal posterior summary

Description

A function to calculate posterior quantities of bivariate normals. See pages 74-80.

Usage

normal.posterior.summary(reps)

Arguments

reps

a matrix where the columns are defined as in the output of biv.norm.post:

Author(s)

Jeff Gill

See Also

biv.norm.post


norr

Description

An 1854 study on mental health in the fourteen counties of Massachusetts yields data on 14 cases. This study was performed by Edward Jarvis (then president of the American Statistical Association)

The variables included in the dataset are:

Usage

data(norr)

opic

Description

private capital investment data. See Page 390.

The variables included in the dataset are:

Usage

data(opic)

pbc.vote

Description

Precinct level data for Palm Beach County, Florida from the 2000 U.S. Presidential Election, see page 149

The variables included in the dataset are:

Usage

data(pbc.vote)

Format

data frame with 516 observations of each precinct in Palm Beach County with 11 explanatory variables

Source

Palm Beach Post collected data from state and federal sources about precinct level data in Palm Beach County for the 2000 US presidential election


plot_walk_G

Description

plot_walk_G code used to produce figure 10.2

Usage

plot_walk_G(walk.mat,sim.rm,X=1,Y=2)

Arguments

walk.mat

walk.mat

sim.rm

sim.rm

X

X

Y

Y

Author(s)

Jeff Gill


plot_walk_MH

Description

plot_walk_MH code used to produce figure 10.4

Usage

plot_walk_MH(walk.mat)

Arguments

walk.mat

walk.mat

Author(s)

Jeff Gill


recidivism

Description

Recidivism Rates. See page 188

The variables included in the dataset are:

Usage

data(recidivism)

Format

data frame with 27 observations of different crime types with 5 explanatory variables

Source

state-level recidivism data as collected by the Oklahoma Department of Corrections from January 1, 1985 to June 30, 1999


retail.sales

Description

Retail sales from 1979 through 1989 based on data provided by the U.S. Department of Commerce through the Survey of Current Business, see page 439

The variables included in the dataset are:

Usage

data(retail.sales)

Format

data frame with 44 observations of statistics for different economic quarters with 7 explanatory variables

Source

U.S. Department of Commerce data from first quarter of 1979 to fourth quarter of 1989


rmultinorm

Description

a function to generate random multivariate Gaussians.

Usage

rmultinorm(n, mu, vmat, tol = 1e-07)

Arguments

n

nu

mu

vector of mean

vmat

variance-covariance matriz

tol

tolerance

Author(s)

Jeff Gill

See Also

biv.norm.post


romney

Description

Analysis of cultural consensus data using binomial likelihood and beta prior.

Usage

romney()

Format

See for yourself. Modify as desired.

Author(s)

Jeff Gill

Source

Romney, A. K. (1999). Culture Consensus as a Statistical Model.
Current Anthropology 40 (Supplement), S103-S115.


sir

Description

Implementation of Rubin's SIR, see pages 338-341 (2nd Edition)

Usage

sir(data.mat,theta.vector,theta.mat,M,m,tol=1e-06,ll.func,df=0)

Arguments

data.mat

A matrix with two columns of normally distributed data

theta.vector

The initial coefficient estimates

theta.mat

The initial vc matrix

M

The number of draws

m

The desired number of accepted values

tol

The rounding/truncing tolerance

ll.func

loglike function for empirical posterior

df

The df for using the t distribution as the approx distribution

Author(s)

Jeff Gill

Examples

## Not run:  
sir <- function(data.mat,theta.vector,theta.mat,M,m,tol=1e-06,ll.func,df=0) {
 importance.ratio <- rep(NA,M)
 rand.draw <- rmultinorm(M,theta.vector,theta.mat,tol = 1e-04)
 if (df > 0)
   rand.draw <- rand.draw/(sqrt(rchisq(M,df)/df))
 empirical.draw.vector <- apply(rand.draw,1,ll.func,data.mat)
 if (sum(is.na(empirical.draw.vector)) == 0) {
   print("SIR: finished generating from posterior density function")
   print(summary(empirical.draw.vector))
 }
 else {
   print(paste("SIR: found",sum(is.na(empirical.draw.vector)),
               "NA(s) in generating from posterior density function, quiting"))
   return()
 }
 if (df == 0) {
   normal.draw.vector <- apply(rand.draw,1,normal.posterior.ll,data.mat)
 }
 else {
   theta.mat <- ((df-2)/(df))*theta.mat
   normal.draw.vector <- apply(rand.draw,1,t.posterior.ll,data.mat,df)
 }
 if (sum(is.na(normal.draw.vector)) == 0) {
   print("SIR: finished generating from approximation distribution")
   print(summary(normal.draw.vector))
 }
 else {
   print(paste("SIR: found",sum(is.na(normal.draw.vector)),
               "NA(s) in generating from approximation distribution, quiting"))
   return()
 }
 importance.ratio <- exp(empirical.draw.vector - normal.draw.vector)
 importance.ratio[is.finite=F] <- 0
 importance.ratio <- importance.ratio/max(importance.ratio)
if (sum(is.na(importance.ratio)) == 0) {
 print("SIR: finished calculating importance weights")
 print(summary(importance.ratio))
}
else {
  print(paste("SIR: found",sum(is.na(importance.ratio)),
              "NA(s) in calculating importance weights, quiting"))
  return()
}
 accepted.mat <- rand.draw[1:2,]
while(nrow(accepted.mat) < m+2) {
  rand.unif <- runif(length(importance.ratio))
  accepted.loc <- seq(along=importance.ratio)[(rand.unif-tol) <= importance.ratio]
  rejected.loc <- seq(along=importance.ratio)[(rand.unif-tol) > importance.ratio]
  accepted.mat <- rbind(accepted.mat,rand.draw[accepted.loc,])
  rand.draw <- rand.draw[rejected.loc,]
  importance.ratio <- importance.ratio[rejected.loc]
  print(paste("SIR: cycle complete,",(nrow(accepted.mat)-2),"now accepted"))
}
accepted.mat[3:nrow(accepted.mat),]
}
# The following are log likelihood functions that can be plugged into the sir function above.

logit.posterior.ll <- function(theta.vector,X) {
  Y <- X[,1]
  X[,1] <- rep(1,nrow(X))
  sum( -log(1+exp(-X
                  -log(1+exp(X)))))
}

normal.posterior.ll <- function(coef.vector,X) {
  dimnames(coef.vector) <- NULL
  Y <- X[,1]
  X[,1] <- rep(1,nrow(X))
  e <- Y - X
  sigma <- var(e)
  return(-nrow(X)*(1/2)*log(2*pi)
         -nrow(X)*(1/2)*log(sigma)
         -(1/(2*sigma))*(t(Y-X)*(Y-X)))
}

t.posterior.ll <- function(coef.vector,X,df) {
  Y <- X[,1]
  X[,1] <- rep(1,nrow(X))
  e <- Y - X
  sigma <- var(e)*(df-2)/(df)
  d <- length(coef.vector)
 return(log(gamma((df+d)/2)) - log(gamma(df/2))
       - (d/2)*log(df)
       -(d/2)*log(pi) - 0.5*(log(sigma))
       -((df+d)/2*sigma)*log(1+(1/df)*
                               (t(Y-X*(Y-X)))))
}

probit.posterior.ll <- function (theta.vector,X,tol = 1e-05) {
  Y <- X[,1]
  X[,1] <- rep(1,nrow(X))
  Xb <- X
  h <- pnorm(Xb)
  h[h<tol] <- tol
  g <- 1-pnorm(Xb)
  g[g<tol] <- tol
  sum( log(h)*Y + log(g)*(1-Y) )
}

## End(Not run)


socatt

Description

Data from the British Social Attitudes (BSA) Survey 1983-1986.

The variables included in the dataset are:

Usage

data(socatt)

strikes

Description

French Coal Strikes, see page 212 and 213

The variables included in the dataset are:

Usage

data(strikes)

Format

data frame with 11 observations of strikes that occurred in different years with 1 explanatory variable

Source

Conell, C. and Cohn, S. (1995). Learning from Other People's Actions: Environmental Variation and Diffusion in French Coal Mining Strikes, 1890-1935. American Journal of Sociology 101, 366-403.

Examples

n <- length(strikes)
r <- 1
s.y <- sum(strikes)

p.posterior.1000000 <- rbeta(1000000,n*r,s.y+0.5)
length(p.posterior.1000000[p.posterior.1000000<0.05])/1000000

par(mar=c(3,3,3,3))
ruler <- seq(0,1,length=1000)
beta.vals <- dbeta(ruler,n*r,s.y+0.5)
plot(ruler[1:200],beta.vals[1:200],yaxt="n",main="",ylab="",type="l")
mtext(side=2,line=1,"Density")
for (i in 1:length(ruler))
  if (ruler[i] < 0.05)
    segments(ruler[i],0,ruler[i],beta.vals[i])
segments(0.04,3,0.02,12.2)
text(0.02,12.8,"0.171")

t_ci_table

Description

A function to calculate credible intervals and make a table. See page 169.

Usage

t_ci_table(coefs,cov.mat,level=0.95,degrees=Inf,quantiles=c(0.025,0.500,0.975))

Arguments

coefs

vector of coefficient estimates, usually posterior means

cov.mat

variance-covariance matrix

level

desired coverage level

degrees

degrees of freedom parameter for students-t distribution assumption

quantiles

vector of desired CDF points (quantiles) to return

Value

quantile.mat matrix of quantiles

Author(s)

Jeff Gill


terrorism

Description

Dataset comparing incidents of terrorism to car accidents, suicide, and murder, see page 140

The variables included in the dataset are:

Usage

data(terrorism)

Format

data frame with 14 observations of death rates for different years with 5 explanatory variables

Source

Falkenrath, R. (2001). Analytical Models and Policy Prescription: Understanding Recent Innovation in U.S. Counterterrorism. Studies in Conflict and Terrorism 24, 159-181.


texas

Description

Poverty in Texas, see page 299

The variables included in the dataset are:

Usage

data(texas)

wars

Description

Data for Chinese wars example, see page 163

The variables included in the dataset are:

Usage

data(wars)

Format

a data frame of 104 observations of different China wars with 15 explanatory variables

Source

Cioffi-Revilla, C. and Lai, D. (1995). War and Politics in Ancient China, 2700 B.C. to 722 B.C.: Measurement and Comparative Analysis. Journal of Conflict Resolution 39, 467-494.