rating-systems-0.1: Implementations of several rating systems: Elo, Glicko, etc

Safe HaskellNone
LanguageHaskell98

Ratings.Types

Synopsis

Documentation

newtype RD Source #

An estimate of the deviation of a player's rating.

Constructors

RD 

Fields

Instances

Eq RD Source # 

Methods

(==) :: RD -> RD -> Bool #

(/=) :: RD -> RD -> Bool #

Fractional RD Source # 

Methods

(/) :: RD -> RD -> RD #

recip :: RD -> RD #

fromRational :: Rational -> RD #

Num RD Source # 

Methods

(+) :: RD -> RD -> RD #

(-) :: RD -> RD -> RD #

(*) :: RD -> RD -> RD #

negate :: RD -> RD #

abs :: RD -> RD #

signum :: RD -> RD #

fromInteger :: Integer -> RD #

Read RD Source # 
Show RD Source # 

Methods

showsPrec :: Int -> RD -> ShowS #

show :: RD -> String #

showList :: [RD] -> ShowS #

newtype Score Source #

The outcome of a matchup. 1 = win, 1/2 = draw, 0 = loss.

Constructors

Score 

Fields

data Result Source #

Outcome of a game that can end in only winlossdraw.

Constructors

Win 
Loss 
Draw 

resultScore :: Result -> Score Source #

Convenient function for converting a Result to a Score.