I have two histograms (freq dist) and I want to take the average of the frequencies in each corresponding bin of the two histograms and get one histogram that displays the average frequencies.
Can I do this with pylab?
a=[] sites = [23,45,32,56,76,87,45,21,34,23,78,90,23,45,21,32,34,54,67,54,33,12,34] import random j=1 for i in range(1,len(sites)): r = random.choice([0,1]) if r == 1: a.append(sites[i] - sites[i-j]) j=1 else: j+=1 import pylab pylab.hist(a, bins=10) pylab.title("hist") pylab.xlabel("length") pylab.ylabel("Count") pylab.show() the snippet code is run several times with different "sites" data to get a several histograms. I want to "average" these histograms in to one.