Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENH] Scatterplot: Implement grouping of selections #2070

Merged
merged 6 commits into from
Mar 13, 2017

Conversation

janezd
Copy link
Contributor

@janezd janezd commented Mar 2, 2017

Instead of annotating selected data with "No" and "Yes", use G0, G1, G2 ... when data is selected is subsequent groups using Shift or Cmd/Ctrl modifier.

Connect File -> Scatter plot, and then Scatter plot to a Table and also to another Scatter plot, both through signal Data (not Selection). Now select several groups in the first scatter plot by using the Shift modifier and see the results in the other scatter plot and table.

The change does not affect the other Scatter plot's output.

We can add a check box "Group selections" to enable or disable this behaviour. However, I think this should be the default behaviour and I see little reason why the user would want to disable it.

Includes
  • Code changes
  • Tests
  • Documentation

@janezd janezd force-pushed the scatterplot-group-selections branch from 7079244 to 64177cf Compare March 2, 2017 21:17
@janezd
Copy link
Contributor Author

janezd commented Mar 2, 2017

@astaric, I defined a GUI for this. :)

@codecov-io
Copy link

codecov-io commented Mar 2, 2017

Codecov Report

Merging #2070 into master will increase coverage by 0.05%.
The diff coverage is 95.34%.

@@            Coverage Diff             @@
##           master    #2070      +/-   ##
==========================================
+ Coverage   70.15%   70.21%   +0.05%     
==========================================
  Files         315      315              
  Lines       54096    54209     +113     
==========================================
+ Hits        37952    38061     +109     
- Misses      16144    16148       +4

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aa30c1f...5052b08. Read the comment docs.

table = Table(
domain, data.X, data.Y,
metas=np.hstack((data.metas, selection.reshape(len(data), 1))))
table.attributes = data.attributes
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

table.ids = data.ids

@janezd janezd force-pushed the scatterplot-group-selections branch 4 times, most recently from addcd1d to e27ddd1 Compare March 3, 2017 21:49
@janezd
Copy link
Contributor Author

janezd commented Mar 3, 2017

radon fails because of an additional case in the switch-ish select method that acts upon different possible keyboard modifiers. There's neither a reasonable way to fix this, nor is there a reason to do so as the method's flow is rather clear.

I'd rather not improve a cc score of a totally unrelated method just to make radon happy.

@janezd janezd force-pushed the scatterplot-group-selections branch from c1319b2 to 3705ad7 Compare March 10, 2017 09:58
@janezd janezd force-pushed the scatterplot-group-selections branch from 3705ad7 to 3c0efd3 Compare March 10, 2017 10:26
@janezd janezd force-pushed the scatterplot-group-selections branch from 3c0efd3 to 5052b08 Compare March 10, 2017 10:58
@astaric astaric merged commit 59c0ded into biolab:master Mar 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants