Logarithmic and Power functions in python for data science:
- exp(a) – When this function is called, it returns the value of ‘e’ raised to the power ‘a’ (e**a).
- log(a, b) – This function will return the logarithmic value of ‘a’ with base ‘b’. In the case base is not mentioned, then natural log is computed.
- log2(a) – This function is there when we need to compute value of log ‘a’ with base 2. This value is more accurate than the log function.
- log10(a) – This function is there for computing value of log ‘a’ with base 10. The value returned is more accurate than values returned by the above functions.
- pow(a,b) – It is there for computing value of ‘a’ raised to the power ‘b’ (a**b).
- sqrt() – This is there to return the square root of a number.