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] Make filters available in Orange.data namespace. #3170

Merged
merged 1 commit into from
Aug 3, 2018

Conversation

thocevar
Copy link
Contributor

@thocevar thocevar commented Jul 30, 2018

Issue

It would be convenient to access filters in the same way as other classes from the data module.

import Orange
tab = Orange.data.Table("iris")
filter = Orange.data.SameValue("petal length", 5.1)
print(len(filter(tab)))
Description of changes

Import everything from filters in data/__init__.py.

Includes
  • Code changes
  • Tests
  • Documentation

@codecov-io
Copy link

codecov-io commented Jul 30, 2018

Codecov Report

Merging #3170 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #3170      +/-   ##
==========================================
+ Coverage   82.54%   82.54%   +<.01%     
==========================================
  Files         337      337              
  Lines       58431    58432       +1     
==========================================
+ Hits        48229    48230       +1     
  Misses      10202    10202

Copy link
Contributor

@lanzagar lanzagar left a comment

Choose a reason for hiding this comment

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

If you want to import * from filter, you have to add an __all__ declaration there.

@lanzagar lanzagar merged commit 410e45c into biolab:master Aug 3, 2018
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.

3 participants