Updates the Transition matrix by subtracting a fraction of the gradient
1 | updateMatrix(Old, New, Transition, n, p, epsilon = 1e-07, alpha = 1e-12)
|
Old |
m by n matrix of values for n choices in m districts |
New |
m by p matrix of values for n choices in m districts |
Transition |
n by b matrix of transition values, all should be positive, row sums should be one |
n |
the number of outcomes in Old and the number of rows in Transition, provided for performance reasons |
p |
the number of outcomes in New and the number of rows in Transition, provided for performance reasons |
epsilon |
'ε'-value for numerical approximation of gradient, defaults to 0.0000001 |
alpha |
step size α, defaults to 0.000000000001 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.