Say I have two vectors x and y
x = {1,3,7,9,20}
y = {1,4,5,6,7}
Now initially i would do something like this
cplot->graph(0)->setData(x, y); ui.myplot->replot();
In my case x remains constant however y tends to change frequently so currently i am doing this
x = {1,3,7,9,20}
y = {1,9,5,6,7} //Only the second y coordinate changed and the others are still the same
so here is what i do
//Update Plot cplot->graph(0)->setData(x, y); ui.myplot->replot();