Vote helpers are functions that take as input an object of class Voters and additional information regarding drift, vibration and the number of iterations to vote on to - reshape the position matrix and role vector to the correct size, resembling the number of iterations - add the specified drift to the voter positions and (calculate and) add the vibration - for voters with random positions, determine the actual positions, per run

create_voter_array(voters, drift, vibration, iter, ...)

# S4 method for Voters
create_voter_array(voters, drift, vibration, iter, ...)

create_role_array(voters, iter, ...)

# S4 method for Voters
create_role_array(voters, iter, no_random_veto,
  no_random_normal, ...)

Arguments

voters

A Voters object.

drift

A vector or matrix of drift values. If vector, then the drift is constant per iteration and the vector must be of length dimension * voter_count. If matrix, the drift can vary per dimension and must be of shape iterations x dimension * voter_count.

vibration

A function with first parameter n that generates random noise.

iter

The number of iterations.

...

Additional keyword arguments.

no_random_veto

Indicator for whether voters with random position can take on the Veto role.

no_random_normal

Indicator for whether random voters can take on the Normal role.