Skip to content

rework gminmax#5105

Merged
mattdowle merged 2 commits intomasterfrom
remove_gsumm_warning
Aug 20, 2021
Merged

rework gminmax#5105
mattdowle merged 2 commits intomasterfrom
remove_gsumm_warning

Conversation

@mattdowle
Copy link
Copy Markdown
Member

@mattdowle mattdowle commented Aug 20, 2021

  • folds gmax into gmin becoming gminmax to avoid the duplicated logic so that future maintenance can be in one place
  • reviewed the logic and changed it slightly; e.g. with default na.rm=FALSE, once an NA has occurred in a group, there is no need to fetch the value of the remaining values in that group
  • moved R API outside loops
  • removed the warnings (closes Remove "no non-missing" warning for character min and max? #4999) and it's now type consistent. I don't know why we ever thought it was a good idea to return Inf, it was just to be consistent with base
  • news item with detailed example

There is some overlap with @MichaelChirico's #4445 here which fixes integer64 support in gmin/gmax. I'll merge that next which should be easier as it's now in one gminmax.

Merging so the NEWS item is published in dev and folk can test dev. Everything in dev is still open for discussion and reconsideration before release.

@mattdowle mattdowle added this to the 1.14.1 milestone Aug 20, 2021
@codecov
Copy link
Copy Markdown

codecov bot commented Aug 20, 2021

Codecov Report

Merging #5105 (dc1cfe6) into master (53278d3) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5105      +/-   ##
==========================================
- Coverage   99.54%   99.54%   -0.01%     
==========================================
  Files          76       76              
  Lines       14691    14592      -99     
==========================================
- Hits        14624    14525      -99     
  Misses         67       67              
Impacted Files Coverage Δ
src/gsumm.c 100.00% <100.00%> (ø)

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 53278d3...dc1cfe6. Read the comment docs.

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.

Remove "no non-missing" warning for character min and max?

2 participants