Stan Math Library
4.9.0
Automatic Differentiation
|
|
inline |
Return the result of transforming the specified scalar or container of values to have a valid correlation value between -1 and 1 (inclusive).
The transform used is the hyperbolic tangent function,
\(f(x) = \tanh x = \frac{\exp(2x) - 1}{\exp(2x) + 1}\).
T | type of value or container |
[in] | x | value or container |
Definition at line 27 of file corr_constrain.hpp.