Aller au contenu
Modèles de Votara Pas encore vérifié

Modèle d’estimation Votara « odds-lite » – probabilité qu’un objet fédéral soit accepté

votara-odds-lite

Éditeur
Votara
Mode d'accès
code
Point d'accès
src/lib/model/odds-lite.ts
Licence
AGPL-3.0 (code), CC BY 4.0 (outputs)
Couverture
Territoire national · de 1981 · à 2025
Lacunes
No pre-vote polls (no open poll data exists, docs/architecture/notes/data-spike.md §(h)). No cantonal simulation — acceptance under the double majority is learned as one outcome. Tie-breakers (Stichfragen) are not estimated. Party recommendations of parties without a swissvotes column (e.g. LPS before 2009, PdA, LdU, LDP, smaller lists) are not counted.
Utilisé dans
STEER-03, STEER-04, STEER-06, STEER-07
Limites connues
Votara estimate, not an official forecast. No opinion polls: the model only knows the authorities' and parties' positions and the parliamentary votes, so campaigns, turnout and late swings are invisible to it. Small sample (382 tested votes, about 10 per year) and drift over time; the 20-year half-life was chosen after looking at backtest results, which makes the backtest slightly optimistic. The double majority (people and cantons) is not modelled separately. Recommendations in the data are the final ones; for upcoming votes some parties may not have decided yet (counted as unknown). Party vote shares come from the previous election and do not follow party switches during a legislature. In the backtest the model has a lower Brier score and log loss than the three baselines, but its accuracy (share of correct yes/no calls) is slightly below "follow the Federal Council". Published on Tim's request on 2026-11-01 (docs/06 "Publication gate"); per-vote estimates are shown only where the server sets VOTARA_ODDS_PUBLIC=1 (flag odds_public, default off), and pnpm model:predict logged the estimates of that day before publication.

Ces données sont-elles à jour ?

Fraîcheur
Pas de mise à jour régulière

Il n’y a pas de source à consulter régulièrement : Votara le calcule lui-même, ou la publication ne change pas.

Période couverte
Pas une série chronologique
Dernière modification des données
Dernière consultation de la source
Aucune consultation enregistrée
Rythme de mise à jour
Calculé par Votara

Note du registre (en anglais) : pnpm model:run after each voting Sunday or data update (rewrites data/model/odds-lite-backtest.json and odds-lite-model.json). Published estimates are appended by pnpm model:predict (needs VOTARA_ODDS_PUBLIC=1); first lines 2026-11-01.

L’état est calculé à chaque construction du site ; cette page le montre au . Résultats des contrôles

Étapes de traitement

  1. Inputs: swissvotes (type, result, recommendations of the Federal Council, the parliament and 12 national parties, final votes in both councils) and bfs-party-strength (party vote shares at National Council elections 1919–2023). Script: scripts/model-run.ts.
  2. Target: P(accepted) = probability that the object is accepted (official result, double majority included where required). Not P(yes share > 50 %).
  3. Features (14): intercept; vote type (mandatory referendum, popular initiative, counter-proposal; reference optional referendum); Federal Council and parliament recommendation (+1 yes, −1 no, 0 none) each with a missing indicator; National Council and Council of States final-vote yes share minus 0.5, each with a missing indicator; party support = vote share of parties recommending yes minus those recommending no; party_unknown_share = vote share of covered parties without a known recommendation.
  4. Party support uses the most recent National Council election held in an earlier calendar year (the data has the election year only). yes/no count; none, free vote, blank ballot, neutral and tie-breaker preferences count as no direction; unknown counts as unknown; a party that no longer exists ("na") follows its successor (CVP and BDP → Die Mitte).
  5. Fit: L2-regularised logistic regression (λ = 1, intercept not penalised), 25 Newton (IRLS) iterations, time-decay case weights with a 20-year half-life. Hand-rolled, deterministic, no dependency.
  6. Backtest: for each year 1981–2025 fit on all decided votes before that year and predict its votes; Brier score, log loss, accuracy, 10 calibration bins, per decade and per type, against three time-weighted baselines (base rate per vote type, follow the Federal Council, follow the parliament). Tie-breakers and pending votes are excluded.
  7. Outputs rounded to 6 decimals. The published model is fitted on every decided vote (1848 – latest voting Sunday) with the same settings.