arrays - python: using numpy.histogram -


I am using:

I have a list a that I want to use in this way:

  numpy.histogram (a, bins = [0.1,0.2,0.3,0.4 ... 6], Category = [0: 6])  
  1. How do I include a set of 0.1 to 6 cans in 0.1 intervals?
  2. How do I specify a range from 0 to 6?

Maybe you search for np.linspace (0,6, num) Are doing = 61) or np.arange (0,6.1,0.1) :

  import np as np a = np.random Random (100) * 6 hist = np Astrogram (a, bins = np.linspace (0,6, num = 61))  

Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -