from numpy import random #here we are using normal function to generate gaussian distribution of size 2 x 4 res = random.normal(size=(2,4)) print('2D Gaussian Distribution as output from normal() function:\n') #printing the result print(res)
from numpy import random #here we are using normal function to generate gaussian distribution of size 2 x 3 x 5 res = random.normal(size=(2,3,5)) print('3D Gaussian Distribution as output from normal() function:\n') #printing the result print(res)
from numpy import random #here we are using normal function to generate gaussian distribution of size 3 x 4 res = random.normal(size=(3,4), loc= 3, scale = 4) print('2D Gaussian Distribution as output from normal() function:\n') #printing the result print(res)
#importing all the required modules and packages from numpy import random import matplotlib.pyplot as mpl import seaborn as sb #here we are using normal function to generate gaussian distribution of size 1000 sb.distplot(random.normal(size=1000, loc = 3, scale = 4), hist=True) #plotting the graph mpl.show()