Description Usage Arguments Value Categories for the category parameter Examples
votes methods
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | cg_vote(congress, chamber, session, id, key = NULL, as = "table", ...)
cg_votes_recent(chamber, key = NULL, as = "table", ...)
cg_votes_type(congress, chamber, type, key = NULL, as = "table", ...)
cg_votes_date(chamber, year = NULL, month = NULL, start_date = NULL,
end_date = NULL, key = NULL, as = "table", ...)
cg_votes_senatenoms(congress, key = NULL, as = "table", ...)
cg_votes_explanations(congress, votes = FALSE, key = NULL, as = "table",
...)
cg_votes_explanations_category(congress, category, key = NULL, as = "table",
...)
cg_votes_explanations_member(member_id, congress, votes = FALSE,
category = NULL, key = NULL, as = "table", ...)
cg_votes_explanations_member(member_id, congress, votes = FALSE,
category = NULL, key = NULL, as = "table", ...)
|
congress |
(character) The number of the Congress this update took place during. |
chamber |
(character) The chamber this update took place in. 'house' or 'senate'. |
session |
(integer) 1 or 2, depending on year (1 is odd-numbered years, 2 is even-numbered years) |
id |
(integer) roll call number, i.e., vote id |
key |
your ProPublica API key; pass in or loads from environment variable
stored as |
as |
(character) IGNORED FOR NOW |
... |
optional curl options passed on to crul::HttpClient.
See |
type |
(character) the vote type, one of missed, party, loneno or perfect |
year |
(integer) a four digit year of the form YYYY |
month |
(integer) a 1 or 2 digit month |
start_date, end_date |
(character) start and end date, of the form YYYY-MM-DD |
votes |
(logical) whether to return votes data or not. default: |
category |
attribute describing the general reason for the absence or incorrect vote. see Details. |
member_id |
(character) The ID of the member to retrieve; it is
assigned by the Biographical Directory of the United States Congress
(http://bioguide.congress.gov/biosearch/biosearch.asp) or can be retrieved
from a |
various things for now, since return objects vary quite a bit among the different votes routes
category
parametervoted-incorrectly: Voted yes or no by mistake
official-business: Away on official congressional business
ambiguous: No reason given
travel-difficulties: Travel delays and issues
personal: Personal or family reason
claims-voted: Vote made but not recorded
medical: Medical issue for lawmaker (not family)
weather: Inclement weather
memorial: Attending memorial service
misunderstanding: Not informed of vote
leave-of-absence: Granted leave of absence
prior-commitment: Attending to prior commitment
election-related: Participating in an election
military-service: Military service
other: Other
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
cg_vote(115, "senate", 1, 17)
cg_votes_recent("senate")
cg_votes_type(114, "house", "missed")
cg_votes_date("senate", year = 2017, month = 1)
cg_votes_date("senate", year = 2017, month = 3)
cg_votes_date("senate", start_date = "2017-01-03", end_date = "2017-01-31")
cg_votes_senatenoms(114)
cg_votes_explanations(114, votes = FALSE)
cg_votes_explanations(114, votes = TRUE)
cg_votes_explanations_category(114, "voted-incorrectly")
cg_votes_explanations_member("S001193", 115, votes = FALSE)
cg_votes_explanations_member("S001193", 115, votes = TRUE)
cg_votes_explanations_member("S001193", 115, votes = TRUE,
category = "personal")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.