Document the label_threshold parameter in get_studies_by_label - #1084
Document the label_threshold parameter in get_studies_by_label#1084lobennett wants to merge 1 commit into
Conversation
|
Thanks for opening this pull request! We have detected this is the first time you have contributed to NiMARE. Please check out our contributing guidelines. Of course, if you want to opt out this time there is no problem at all with adding your name later. You will be always welcome to add it in the future whenever you feel it should be listed. |
Reviewer's guide (collapsed on small PRs)Reviewer's GuideUpdates the docstring for Dataset.get_studies_by_label to correctly describe the label_threshold parameter’s behavior, semantics, and default value, without changing any runtime behavior. File-Level Changes
Assessment against linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1084 +/- ##
=======================================
Coverage 85.50% 85.50%
=======================================
Files 56 56
Lines 11248 11248
=======================================
Hits 9618 9618
Misses 1630 1630 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
The
label_thresholdparameter ofDataset.get_studies_by_labelwas documented only as "Default is 0.5.", which is both wrong (the default is0.001) and unexplained.This rewrites the entry to state the correct default and explain the threshold: a study is included when its annotation value for every requested label is
>= label_threshold, and for Neurosynth-style annotations those values are tf-idf weights (higher = the term is more important to that study's text relative to the corpus), so the threshold is only interpretable within the corpus the annotations were derived from. (Per the discussion in the issue.)Docstring-only; no behavior change.
flake8 nimare/dataset.pypasses.Closes #950
Summary by Sourcery
Documentation: