Skip to content

feat: add loop.plot()#637

Closed
nulinspiratie wants to merge 3 commits intomicrosoft:masterfrom
nulinspiratie:feature/loop_plot
Closed

feat: add loop.plot()#637
nulinspiratie wants to merge 3 commits intomicrosoft:masterfrom
nulinspiratie:feature/loop_plot

Conversation

@nulinspiratie
Copy link
Contributor

Fixes #issuenumber.

Changes proposed in this pull request:
Add loop.plot() method to ActiveLoop, which automatically attaches it to the task of the loop. It cleans up the measurement code, as you can now use a single lineloop.plot(data_set.data_vals) instead of:

plot = MatPlot(data_set.data_vals)
loop.attach_bg_task(plot.update)

When combined with PR #636 , it becomes especially easy to create a plot with multiple subplots using a single readable line.

I didn't add it to Loop, but only to ActiveLoop. I'm not sure why we have both, is it also needed in Loop?

Currently only works with MatPlot, as I'm not sure to determine when to use MatPlot, and when to use QTPlot

@giulioungaretti @WilliamHPNielsen @jenshnielsen

Add loop.plot() method, which automatically attaches it to the
background task of the loop. Currently only works with MatPlot, not sure
how to make it know when to choose QTPlot
@astafan8
Copy link
Contributor

@nulinspiratie (also @WilliamHPNielsen @jenshnielsen @giulioungaretti )
What is the status?

@astafan8
Copy link
Contributor

is this PR still relevant and useful? :)

@codecov
Copy link

codecov bot commented Sep 14, 2019

Codecov Report

Merging #637 into master will decrease coverage by <.01%.
The diff coverage is 40%.

@@            Coverage Diff            @@
##           master    #637      +/-   ##
=========================================
- Coverage   67.21%   67.2%   -0.01%     
=========================================
  Files         145     145              
  Lines       17951   17956       +5     
=========================================
+ Hits        12065   12068       +3     
- Misses       5886    5888       +2

@WilliamHPNielsen
Copy link
Contributor

I think it's fair to close this PR, since we'll do no further development of the old loop.

@jenshnielsen
Copy link
Collaborator

Agreed

@nulinspiratie nulinspiratie deleted the feature/loop_plot branch March 25, 2020 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants