# First, make sure your personal PVS API key is saved as character string in the pvs.key variable:
pvs.key <- "yourkey"
# get a data frame of committees according to all type/state combinations
committees <- Committee.getCommitteesByTypeState(typeId=list("H","S"),
stateId=list("NY","NJ"), all=TRUE)
committees
# get a data frame of committees according to the exact type/state combinations
# (i.e., "H"/"NY", "S"/"NJ")
committees <- Committee.getCommitteesByTypeState(typeId=list("H","S"),
stateId=list("NY","NJ"), all=FALSE)
committees
Run the code above in your browser using DataLab