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

[MRG] update output from gather w/o abundances, so that abund output is empty #1328

Merged
merged 2 commits into from
Feb 15, 2021

Conversation

ctb
Copy link
Contributor

@ctb ctb commented Feb 15, 2021

Based on dib-lab/genome-grist#45, there is a potential confusion where sourmash gather outputs CSVs that have zeros in three columns (average_abund, median_abund, std_abund) when NOT using abundances in calculations.

This PR changes output CSVs so that None is used as default value, which results in empty CSV fields. I think this is much clearer than putting a zero in the field!

Addresses part of dib-lab/genome-grist#45 (comment)

TODO:

  • tests for new behavior

Checklist

  • Is it mergeable?
  • make test Did it pass the tests?
  • make coverage Is the new code covered?
  • Did it change the command-line interface? Only additions are allowed
    without a major version increment. Changing file formats also requires a
    major version number increment.
  • Was a spellchecker run on the source code and documentation after
    changes were made?

@codecov
Copy link

codecov bot commented Feb 15, 2021

Codecov Report

Merging #1328 (05d902d) into latest (128e50c) will increase coverage by 5.33%.
The diff coverage is 92.30%.

Impacted file tree graph

@@            Coverage Diff             @@
##           latest    #1328      +/-   ##
==========================================
+ Coverage   88.73%   94.06%   +5.33%     
==========================================
  Files         123       96      -27     
  Lines       18116    14509    -3607     
  Branches     1398     1399       +1     
==========================================
- Hits        16075    13648    -2427     
+ Misses       1802      622    -1180     
  Partials      239      239              
Flag Coverage Δ
python 94.06% <92.30%> (-0.01%) ⬇️
rust ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/sourmash/commands.py 82.22% <50.00%> (-0.18%) ⬇️
src/sourmash/search.py 91.15% <100.00%> (ø)
tests/test_sourmash.py 99.41% <100.00%> (+<0.01%) ⬆️
src/core/src/sketch/hyperloglog/estimators.rs
src/core/src/index/sbt/mhbt.rs
src/core/tests/minhash.rs
src/core/src/index/sbt/mod.rs
src/core/src/ffi/cmd/compute.rs
src/core/src/sketch/nodegraph.rs
src/core/src/cmd.rs
... and 20 more

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 128e50c...05d902d. Read the comment docs.

@ctb
Copy link
Contributor Author

ctb commented Feb 15, 2021

Ready for review & merge @luizirber!

@ctb
Copy link
Contributor Author

ctb commented Feb 15, 2021

@bluegenes could review it also, if she's feeling like it ;)

@ctb ctb changed the title [WIP] update output from gather w/o abundances, so that abund output is empty [MRG] update output from gather w/o abundances, so that abund output is empty Feb 15, 2021
Copy link
Contributor

@bluegenes bluegenes left a comment

Choose a reason for hiding this comment

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

Nice - None/ empty columns are much clearer than zeroes!

lgtm

@ctb
Copy link
Contributor Author

ctb commented Feb 15, 2021

thank you!

@ctb ctb merged commit bf5eeba into latest Feb 15, 2021
@ctb ctb deleted the update/gather_noabund_none branch February 15, 2021 19:41
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.

None yet

2 participants