compute_sigmoid_second_derivative#

pymc_marketing.mmm.utils.compute_sigmoid_second_derivative(x, alpha, lam)[source]#

Compute the second derivative of the extended sigmoid function.

The second derivative of a function gives us information about the curvature of the function. In the context of the sigmoid function, it helps us identify the inflection point, which is the point where the function changes from being concave up to concave down, or vice versa.

Parameters:
xfloat

The input value for which the second derivative is to be computed.

alphafloat

The asymptotic maximum or ceiling value of the sigmoid function.

lamfloat

The parameter that affects how quickly the function approaches its upper and lower asymptotes.

Returns:
float

The second derivative of the sigmoid function at the input value.