Learn R Programming

TrueSkillThroughTime (version 1.0.0)

Gaussian: Gaussian

Description

Gaussian class

Usage

Gaussian(mu = 0, sigma = 1)

Pi(N)

# S4 method for Gaussian Pi(N)

Tau(N)

# S4 method for Gaussian Tau(N)

forget(N, gamma, t)

# S4 method for Gaussian,numeric,numeric forget(N, gamma, t)

isapprox(N, M, tol = 1e-04)

# S4 method for Gaussian,Gaussian,numeric isapprox(N, M, tol = 1e-04)

# S4 method for Gaussian,Gaussian +(e1, e2)

# S4 method for Gaussian,Gaussian -(e1, e2)

# S4 method for Gaussian,Gaussian *(e1, e2)

# S4 method for Gaussian,Gaussian /(e1, e2)

# S4 method for Gaussian,Gaussian ==(e1, e2)

# S4 method for Player performance(a)

Value

Gaussian object

Arguments

mu

A number, the mean of the Gaussian distribution.

sigma

A number, the standar deviation of the Gaussian distribution.

N

A Gaussian object

gamma

The dynamic factor, the dynamic uncertainty

t

The elapsed time

M

A Gaussian object

tol

The tolerance threshold for comparitions

e1

A Gaussian object

e2

A Gaussian object

a

A Gaussian object

Examples

Run this code
N01 = Gaussian(0,1); N12 = Gaussian(mu = 1, sigma = 2)
N06 = Gaussian(); Ninf = Gaussian(0,Inf)
N01 * Ninf == N01
N01 * N12
N01 / N12
N01 + N12
N01 - N12
Pi(N12) == 1/(N12@sigma^2)
Tau(N12) == N12@mu/(N12@sigma^2)
Nnew = forget(N = N01, gamma = 0.01, t = 100)
isapprox(Nnew, Gaussian(N01@mu,sqrt(N01@sigma^2+100*(0.01^2))), tol=1e-6)

Run the code above in your browser using DataLab