Efficient way to do histogram

29 views
Skip to first unread message

Diogo Valada

unread,
Aug 20, 2016, 3:27:56 PM8/20/16
to pyqtgraph
Hey
Is there a way I can set a default y for every absent integer x axis value?

For Example:

I send this lists to the plotter:
x=[1, 4, 6]
y=[8, 9, 7]
And I want y(2)=y(3)=y(5)=0

Is there a way to set this rule?
Basically, what I want is to do an histogram-like graph, in which i don't have non present x values (in the list) have a corresponding 0 on the graph.
Reply all
Reply to author
Forward
0 new messages