pd_mdsmat: Matrices of weights and distances.

Description Usage Arguments Author(s)

View source: R/pd_mdsmat.R

Description

Creates matrices of weights and distances, and sets minimum number of observations for parties and issues.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
pd_mdsmat <- (
    data,
    party_var,
    issue_var,
    proximity_var,
    year_var,
    years=NULL,
    noweight = FALSE,
    row = FALSE,
    cell = FALSE,
    min = 1,
    imin = NULL
  )

Arguments

data

A dataset containing COSA election campaign data.

party_var

Name of the party variable.

issue_var

Name of the issue variable.

proximity_var

Name of the proximity variable (i.e. direction).

years

Years to be included as a vector of characters.

noweight

If noweight is TRUE, the matrix of weights is not computed.

row

If TRUE, specifies that weights are computed separately for each party (and within each year if the option year is specified).

cell

If TRUE, weights are computed separately for each election.

min

Minimum number of observations for a party in an election.

imin

Minimum percentage of observations for an issue to be included.

Author(s)

Ioana-Elena Oana


nenaoana/MDScosa documentation built on April 12, 2020, 10:20 a.m.