Learn R Programming

eiCompare (version 3.0.4)

ei_good: EI iterative estimation via Goodman's Regression

Description

EI iterative estimation via Goodman's Regression

Usage

ei_good(data, cand_cols, race_cols, totals_col)

Value

matrix with precinct results, columns = race groups, rows = candidates

Arguments

data

A data.frame() object containing precinct-level turnout data by race and candidate

cand_cols

A character vector listing the column names for turnout for each candidate

race_cols

A character vector listing the column names for turnout by race

totals_col

The name of the column containing total votes cast in each precinct

Author

Loren Collingwood <loren.collingwood@ucr.edu>

Ari Decter-Frain <agd75@cornell.edu>

References

eiPack King et. al. (http://gking.harvard.edu/eiR)

L. A. Goodman. Ecological regressions and behavior of individuals. American Sociological Review, 1953.