test_ipf.R: match groups before test equal #6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adjustment to the test to cope if
aggregate()
returns the groups in a different order. The addedmatch()
ensures that the result for each group is compared without an assumption that thenew
andold
result has the groups in the same order.With the current dev version of data.table 1.13.7 (to be released as 1.13.8), news item 2 is :
which affects the
fintersect()
calls increate_common_data()
. The first call affected being https://github.com/elbersb/segregation/blob/master/R/ipf.R#L93. Eventually the test receivesnew
andold
containing the correct group results as before, but in a slightly different order, as follows.This was highlighted by revdep testing of data.table in dev, #5.
Linking to the revdep status tracking issue, Rdatatable/data.table#4866.
Linking to the change to
data.table::fintersect()
, Rdatatable/data.table#4716.If it looks ok to you, there's no rush at all but when you have a chance could you merge and publish to CRAN please. Otherwise
data.table
will breaksegregation
's tests on CRAN on the next update. Thanks! I checked that with this PR,segregation
passesR CMD check
with both current release ofdata.table
(1.13.6), and the dev version (so you don't need to wait for the new version to be released).