Smoothed version of "argmax"; also known as the inverse multinomial logit.
Usage
softmax(x, ...)
# S3 method for default
softmax(x, ...)
# S3 method for numeric
softmax(x, ...)
# S3 method for matrix
softmax(x, margin = 1, ...)
Arguments
- x
objects of vector or matrix.
- ...
These dots are for future extensions and must be empty.
- margin
integer. Dimension to apply the function over,
defaults to 1 (rows).