Skip to main content

consensus

Function consensus 

Source
pub fn consensus(layout: &Layout, id: &str) -> Result<String>
Expand description

The DeGroot consensus over an issue’s ballots, weighted by who the group listens to.

vote counts; this weighs. Both are printed, because the useful thing about the weighted answer is where it differs from the count, and a reader shown only one of them cannot tell whether the trust configuration did anything.

§Errors

Returns an error if the corpus cannot be read, id is not in it, or the configuration names a weight the iteration cannot use.