Log

import numpy as np
import numpy
import matplotlib.pyplot as plt 
in_array = [1, 3, 5] 
print ("Input array : ", in_array)
Input array :  [1, 3, 5]
out_array = np.log1p(in_array) 
print ("Output array : ", out_array)
Output array :  [0.69314718 1.38629436 1.79175947]
y = out_array 
plt.plot(in_array, y, color = 'blue', marker = "*")
[<matplotlib.lines.Line2D at 0x10fefbe80>]
# red for numpy.log1xp() 
plt.plot(out_array, y, color = 'red', marker = "o") 
plt.title("numpy.log1p()") 
plt.xlabel("X") 
plt.ylabel("Y") 
plt.show()

png