# HG changeset patch # User mheinzl # Date 1559559768 14400 # Node ID 55c7e49eea889aa436cf6386db0d76d12f4f4012 # Parent 5e1450eda945b149c38d466a05e5013369b9efd5 planemo upload for repository https://github.com/monikaheinzl/duplexanalysis_galaxy/tree/master/tools/fsd commit b8a2f7b7615b2bcd3b602027af31f4e677da94f6-dirty diff -r 5e1450eda945 -r 55c7e49eea88 fsd.py --- a/fsd.py Mon Jun 03 06:58:20 2019 -0400 +++ b/fsd.py Mon Jun 03 07:02:48 2019 -0400 @@ -343,24 +343,29 @@ #print(w) # linewidth=1, - print(numpy.sum(y)) - print(float(numpy.sum(y))) - print(x) - new_y = numpy.concatenate((numpy.array([yi / float(numpy.sum(y)) for yi in y]))) - print(new_y.shape) - new_y = numpy.array(new_y).reshape((len(new_y))) - print(new_y.shape) - print(new_y) + #print(numpy.sum(y)) + #print(float(numpy.sum(y))) + #print(x) + #print(new_y.shape) + #new_y = numpy.array(new_y).reshape((len(new_y))) + #print(new_y.shape) + #print(new_y) + + #new_y_heights = [x[0] for x in new_y] #print(new_y_heights) #print(new_y.shape) if to_plot[l] == "Relative frequencies": + print("relative") + new_y = list(numpy.concatenate((numpy.array([yi / float(numpy.sum(y)) for yi in y])))) + counts2_rel = ax.bar(x, new_y, align="edge", width=w, edgecolor="black", label=label[i], alpha=0.8, color=colors[i]) else: + y = list(y) counts2 = ax.bar(x, y, align="edge", width=w, edgecolor="black", label=label[i], alpha=0.8, color=colors[i]) if i == len(list_to_plot2):