Learn R Programming

congressbr (version 0.2.2)

sen_votes: Returns voting information from the Senate floor for the date requested

Description

Returns voting information from the Senate floor for the date requested.

Usage

sen_votes(date = NULL, end_date = NULL, binary = TRUE, ascii = TRUE)

Arguments

date

character or integer. Format YYYYMMDD.

end_date

character or integer. Format YYYYMMDD. If end_date is supplied, information on all votes between the initial date (date) and end_date is returned. See the notes below.

binary

logical. If TRUE, the default, transforms votes into 1 for "yes", 0, for "no" and NA for everything else. If FALSE, returns a character vector of vote decisions.

ascii

logical. If TRUE, the default, strips Latin characters from the results.

Value

A tibble, of classes tbl_df, tbl and data.frame.

Examples

Run this code
# NOT RUN {
sen_votes(date = "20130516")

# Some votes are secret:
ssshhh <- sen_votes("20160301", binary = FALSE)

# All votes between two periods (might take a little while):
longer <- sen_votes(date = "20160301", end_date = "20160415")
# }

Run the code above in your browser using DataLab