Python | Numpy np.lognormal() method Last Updated : 13 Oct, 2019 Summarize Comments Improve Suggest changes Share Like Article Like Report With the help of np.lognormal() method, we can get the log normal distribution values using np.lognormal() method. Syntax : np.lognormal(mean, sigma, size) Return : Return the array of log normal distribution. Example #1 : In this example we can see that by using np.lognormal() method, we are able to get the log normal distribution using this method. Python3 1=1 # import numpy import numpy as np # using np.lognormal() method gfg = np.random.lognormal(0.4, 1, 20) print(gfg) Output : [1.79018885 5.92534286 1.00603156 3.81479755 1.25423563 1.07349624 1.73633784 3.94777056 0.46396803 6.94550919 0.99394585 5.18915825 0.44592035 2.0444561 1.53886748 0.55812707 0.89377027 0.72423754 1.54571163 0.12100189] Example #2 : Python3 1=1 # import numpy import numpy as np # using np.lognormal() method gfg = np.random.lognormal(0.5, 3, 20) print(gfg) Output : [3.07682048e+00 9.44352316e+01 6.87353998e+03 3.05831375e+01 1.46571273e+00 3.90269093e+01 1.69201799e+01 3.85820572e+00 1.06782865e+02 5.18854252e-02 1.49602754e-01 8.61251480e-02 1.12008497e+03 3.39899978e+02 3.89940243e+01 4.92388063e-01 9.18305486e-01 5.89074684e-02 3.78148976e+00 2.38199349e+00] Comment More infoAdvertise with us Next Article numpy.floor() in Python J jitender_1998 Follow Improve Article Tags : Technical Scripter Python Python-numpy Python numpy-arrayManipulation Practice Tags : python Similar Reads Python | Numpy np.logseries() method With the help of np.logseries() method, we can get the log series in the form of an array by using np.logseries() method. Syntax : np.logseries(p, size) Return : Return an array of log series. Example #1 : In this example we can see that by using np.logseries() method, we are able to get an array of 1 min read numpy.floor() in Python The numpy.floor() function returns the largest integer less than or equal to each element in the input array. It effectively rounds numbers down to the nearest whole number. Let's understand with an example:Pythonimport numpy as np a = [0.5, 1.5, 2.5, 3, 4.5, 10.1] res = np.floor(a) print("Floored:" 1 min read numpy.logaddexp() in Python numpy.logaddexp() function is used to calculate Logarithm of the sum of exponentiations of the inputs. This function is useful in statistics where the calculated probabilities of events may be so small as to exceed the range of normal floating point numbers. In such cases, the logarithm of the calcu 2 min read numpy.logaddexp2() in Python numpy.logaddexp2() function is used to calculate Logarithm of the sum of exponentiations of the inputs in base-2. This function is useful in machine learning when the calculated probabilities of events may be so small as to exceed the range of normal floating point numbers. In such cases, the base-2 2 min read Python | Numpy numpy.ndarray.__mod__() With the help of Numpy numpy.ndarray.__mod__(), every element in an array is operated on binary operator i.e mod(%). Remember we can use any type of values in an array and value for mod is applied as the parameter in ndarray.__mod__(). Syntax: ndarray.__mod__($self, value, /) Return: self%value Exam 1 min read numpy.log1p() in Python numpy.log1p(arr, out = None, *, where = True, casting = 'same_kind', order = 'K', dtype = None, ufunc 'log1p') : This mathematical function helps user to calculate natural logarithmic value of x+1 where x belongs to all the input array elements. log1p is reverse of exp(x) - 1. Parameters : array : [ 2 min read Like