Returns a list with a metadata item per ballot type, ballot date, canton and optionally political level.
Usage
combos_ballot_types(
ballot_dates = all_ballot_dates,
lvls = all_lvls,
cantons = all_cantons,
ballot_types = all_ballot_types,
incl_lvl = TRUE
)
Arguments
- ballot_dates
FOKUS-covered ballot date(s). One or more of
"2018-09-23"
"2018-11-25"
"2019-10-20"
"2020-09-27"
"2020-10-18"
"2021-11-28"
"2023-06-18"
"2024-10-20"
- lvls
Political level(s). One or more of
"cantonal"
and"federal"
.- cantons
FOKUS-covered canton name(s). One or more of
"aargau"
- ballot_types
Ballot type(s). One or more of
"referendum"
or"election"
- incl_lvl
Whether or not to include the political levels in the resulting list. Setting this to
FALSE
potentially results in fewer combinations.
See also
Other combination functions:
add_vars_to_combos()
,
combos_elections()
,
combos_proposal_arguments()
,
combos_proposal_main_motives()
,
combos_proposals()
Other fundamental predicate functions:
ballot_types()
,
cantons()
,
election_nrs()
,
election_prcds()
,
has_ballot_type()
,
has_election()
,
has_election_nrs()
,
has_lvl()
,
has_proposal_nrs()
,
has_referendum()
,
is_representative()
,
lvls()
,
n_elections()
,
n_proposals()
,
prcds()
,
proposal_nrs()
,
proposal_qstn_groups()
,
qstn_groups_proposal_nrs()
,
survey_channels()
Examples
# of all covered ballots
fokus::combos_ballot_types()
#> [[1]]
#> [[1]]$ballot_date
#> [1] "2018-09-23"
#>
#> [[1]]$lvl
#> [1] "cantonal"
#>
#> [[1]]$canton
#> [1] "aargau"
#>
#> [[1]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[2]]
#> [[2]]$ballot_date
#> [1] "2018-09-23"
#>
#> [[2]]$lvl
#> [1] "federal"
#>
#> [[2]]$canton
#> [1] "aargau"
#>
#> [[2]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[3]]
#> [[3]]$ballot_date
#> [1] "2018-11-25"
#>
#> [[3]]$lvl
#> [1] "cantonal"
#>
#> [[3]]$canton
#> [1] "aargau"
#>
#> [[3]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[4]]
#> [[4]]$ballot_date
#> [1] "2018-11-25"
#>
#> [[4]]$lvl
#> [1] "federal"
#>
#> [[4]]$canton
#> [1] "aargau"
#>
#> [[4]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[5]]
#> [[5]]$ballot_date
#> [1] "2019-10-20"
#>
#> [[5]]$lvl
#> [1] "cantonal"
#>
#> [[5]]$canton
#> [1] "aargau"
#>
#> [[5]]$ballot_type
#> [1] "election"
#>
#>
#> [[6]]
#> [[6]]$ballot_date
#> [1] "2019-10-20"
#>
#> [[6]]$lvl
#> [1] "federal"
#>
#> [[6]]$canton
#> [1] "aargau"
#>
#> [[6]]$ballot_type
#> [1] "election"
#>
#>
#> [[7]]
#> [[7]]$ballot_date
#> [1] "2020-09-27"
#>
#> [[7]]$lvl
#> [1] "cantonal"
#>
#> [[7]]$canton
#> [1] "aargau"
#>
#> [[7]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[8]]
#> [[8]]$ballot_date
#> [1] "2020-09-27"
#>
#> [[8]]$lvl
#> [1] "federal"
#>
#> [[8]]$canton
#> [1] "aargau"
#>
#> [[8]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[9]]
#> [[9]]$ballot_date
#> [1] "2020-10-18"
#>
#> [[9]]$lvl
#> [1] "cantonal"
#>
#> [[9]]$canton
#> [1] "aargau"
#>
#> [[9]]$ballot_type
#> [1] "election"
#>
#>
#> [[10]]
#> [[10]]$ballot_date
#> [1] "2021-11-28"
#>
#> [[10]]$lvl
#> [1] "federal"
#>
#> [[10]]$canton
#> [1] "aargau"
#>
#> [[10]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[11]]
#> [[11]]$ballot_date
#> [1] "2023-06-18"
#>
#> [[11]]$lvl
#> [1] "cantonal"
#>
#> [[11]]$canton
#> [1] "aargau"
#>
#> [[11]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[12]]
#> [[12]]$ballot_date
#> [1] "2023-06-18"
#>
#> [[12]]$lvl
#> [1] "federal"
#>
#> [[12]]$canton
#> [1] "aargau"
#>
#> [[12]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[13]]
#> [[13]]$ballot_date
#> [1] "2024-10-20"
#>
#> [[13]]$lvl
#> [1] "cantonal"
#>
#> [[13]]$canton
#> [1] "aargau"
#>
#> [[13]]$ballot_type
#> [1] "election"
#>
#>
# only of 2023-06-18 ballot in aargau
fokus::combos_ballot_types(ballot_dates = "2023-06-18",
cantons = "aargau")
#> [[1]]
#> [[1]]$ballot_date
#> [1] "2023-06-18"
#>
#> [[1]]$lvl
#> [1] "cantonal"
#>
#> [[1]]$canton
#> [1] "aargau"
#>
#> [[1]]$ballot_type
#> [1] "referendum"
#>
#>
#> [[2]]
#> [[2]]$ballot_date
#> [1] "2023-06-18"
#>
#> [[2]]$lvl
#> [1] "federal"
#>
#> [[2]]$canton
#> [1] "aargau"
#>
#> [[2]]$ballot_type
#> [1] "referendum"
#>
#>