Description Usage Arguments Details Value Author(s) See Also Examples
When two numbers that are on the log scale must be summed, transforming them back to the non-log scale and taking the sum is slow. This function takes the exp() of the values only when neccessary.
1 | addLog(x, y)
|
x |
Numeric containing a value on the log scale. |
y |
Numeric containing a value on the log scale. |
This function checks to see if the difference between the maximum value and the other value is less than the machine precision. If it is, then the exp() is taken for those values that differ by less than the machine precision, they are summed and returned to a log scale. If the maximum value is differs from the other values by greater than the machine precision, then return the maximum value.
Numeric value containing the sum of the arguments on a log scale.
Daniel Gatti
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.