np.histogram outputs?? - Python

Trying to understand what kind of output do I get from the histogram function.

phase = mod(phase,Nper*2*pi)
cl_phase = arange(0,Nper*2*pi+step,step)
c,p = histogram(phase,cl_phase)

while 0 in c:
    step = step*2
    cl_phase = arange(0,Nper*2*pi+step,step)
    c,p = histogram(phase,cl_phase)

This is what I am trying to understand. I dont comprehend the very first line and also the objective of using the histogram function (and the outputs it provides)

Not sure if this is enough for anyone take any sort of conclusion, but anything that you might understand from this would help me a lot to shed some light on this issue! I also don't understand the argument for the while loop. Why is zero being "taken out"?

Thank you in advance!

PS: Nper is the number of periods (in this case it's a wave) I am analysing Phase is a np.array

Upvotes: 0

Views: 69

Answers (0)

Related Questions