Accurately computes the logarithm of the sum of exponentials across rows or columns
Accurately computes the logarithm of the sum of exponentials across rows or columns.
rowLogSumExps(lx, rows = NULL, cols = NULL, na.rm = FALSE, dim. = dim(lx), ...) colLogSumExps(lx, rows = NULL, cols = NULL, na.rm = FALSE, dim. = dim(lx), ...)
These methods are implemented in native code and have been optimized for speed and memory.
Native implementation by Henrik Bengtsson. Original R code by Nakayama ??? (Japan).
To calculate the same on vectors, logSumExp
().
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.