speech_rollcall {speech} | R Documentation |
Detects roll-call
Description
Detects roll-call in floor speeches and converts them to a dataset.
Returns a summary of a rollcall vote object.
Usage
speech_rollcall(file, add.error.sir = NULL, rm.error.leg = NULL)
## S3 method for class 'nominal'
summary(object, ...)
Arguments
file |
list or character vector specifying the path or URL to a PDF file. It can be one or more files. |
add.error.sir |
character vector. It allows to specify different ways in which
the term that orders the speeches could be miswritten: sir. By default it is |
rm.error.leg |
character vector. It allows to add legislator's names
to be eliminated. By default it is |
object |
an object of class |
... |
additional parameter. |
Details
This function detects roll-call votes on floor speeches. It only detects votes where the vote can be affirmative or negative. This leaves out a set of roll-call votes, such as those for the allocation of positions in the chamber.
Value
data.frame with the following variables:
legislator
: Name of the legislatorvote
: Voting, 1 = affirmative, 0 = Negativeargument
:If the legislator justifies the vote, it is worth 1, otherwise 0.speech
: Speechchamber
: Chamberdate
: Datelegislature
: Legislaturerollcall
: Number of roll-call in sessionid
: Idsex
: Sex of legislator
data.frame with the following variables:
Chamber
: ChamberDate
: DateLegislators
: Number of legislators in the votingAffirmative
: Number of affirmative votesNegative
: Number of negative votesprop_AF
: Proportion of affirmative votesprop_NG
: Proportion of negative votesprop_women
: Proportion of women in the votingprop_arg
: Proportion of legislators justifying the voterc
: Number of roll-call in session
Examples
# url <- speech::speech_url(chamber = "D", from = "14-04-2004", to = "14-04-2004")
# out <- speech_rollcall(file = url)
# summary(out)