Event
- class poisson_approval.Event(candidate_x, candidate_y, candidate_z, tau)[source]
An event with all its attributes: magnitudes, offsets, asymptotic if possible (abstract class).
- Parameters
candidate_x (str) – A candidate (e.g.
'a'
).candidate_y (str) – A candidate (e.g.
'b'
).candidate_z (str) – A candidate (e.g.
'c'
).tau (TauVector) – A tau-vector.
- asymptotic
The asymptotic development of the probability of the event when n tends to infinity.
- Type
- mu
Shortcut for
asymptotic.mu
.- Type
Number,
sp.nan
,np.nan
,- sp.oo
or- np.inf
- nu
Shortcut for
asymptotic.nu
.- Type
Number,
sp.nan
,np.nan
,- sp.oo
or- np.inf
- xi
Shortcut for
asymptotic.xi
.- Type
Number,
sp.nan
,np.nan
,- sp.oo
or- np.inf
- phi_ab
The offset for this kind of ballot. An offset is
np.nan
if it is not defined. Other offsets are denotedphi_a
, etc.- Type
Number or
np.nan
- phi
The dictionary of the offsets. For example,
self.phi['a']
is just an alternate notation forself.phi_a
.- Type
dict
- psi_ab
The pseudo-offset for this kind of ballot. It is equal to
phi_ab
if it exists, andphi_a * phi_b
otherwise. Similarly, the pseudo-offsetpsi_a
is equal tophi_a
if it exists, andphi_ab * phi_ac
otherwise. Other pseudo-offsets are denotedpsi_b
, etc.- Type
Number or
np.nan
- psi
The dictionary of pseudo-offsets. For example,
self.psi['a']
is just an alternate notation forself.psi_a
.- Type
dict
Notes
The permutation of
candidate_x
,candidate_y
andcandidate_z
is generally important in the subclasses. For example, inEventDuo
, we consider a tie between candidatesx
andy
(hence in that case, if is the same ifx
andy
are exchanged, but not ifx
andz
are exchanged for example).Examples
Cf.
EventPivotWeak
.