T-200: Decouple R-loop search from MorphyLib; add concavity parameter#216
Open
ms609 wants to merge 10 commits intocpp-searchfrom
Open
T-200: Decouple R-loop search from MorphyLib; add concavity parameter#216ms609 wants to merge 10 commits intocpp-searchfrom
ms609 wants to merge 10 commits intocpp-searchfrom
Conversation
- New R/NativeSearch.R: PrepareNativeData, CleanNativeData, NativeLength, NativeBootstrap (4 exported functions) - TreeSearch(), Ratchet(), Jackknife() now default to native scorer - New 'concavity' parameter on all three functions - Jackknife() rewritten to support both native and morphy paths - EdgeListSearch() default scorer changed to NativeLength - Deprecated: PhyDat2Morphy, UnloadMorphy, MorphyLength, MorphyTreeLength, MorphyBootstrap - Vignette custom.Rmd IW section rewritten (was ~150 lines of MorphyLib scaffolding, now 30 lines using concavity parameter) - test-NativeSearch.R: 7 tests covering all new functions - test-CustomSearch.R: updated to use native defaults
Adds NativeSearch.Rd and updates Jackknife.Rd, Ratchet.Rd, TreeSearch.Rd with new concavity parameter and default changes.
e25cbab to
f59a193
Compare
- inst/WORDLIST: add 'cleanup' and 'phyDat' - R/mpl_morphy_objects.R: wrap PhyDat2Morphy/MorphyWeights @examples in \donttest{}; use suppressWarnings() for UnloadMorphy in GapHandler and SingleCharMorphy examples - R/Morphy.R: wrap constraint example with suppressWarnings() so internal PhyDat2Morphy/UnloadMorphy calls don't emit warnings Fixes 1 ERROR (spelling) + 1 WARNING (deprecated fns in examples)
Wrap PhyDat2Morphy() and UnloadMorphy() calls in suppressWarnings()
in the \examples{} sections of GapHandler.Rd, MorphyWeights.Rd,
PhyDat2Morphy.Rd, RearrangeEdges.Rd, and SingleCharMorphy.Rd.
Wrap Morphy() in suppressWarnings() in the \donttest{} block of
Morphy.Rd -- Morphy() calls PhyDat2Morphy/UnloadMorphy internally via
lapply/vapply, generating the 'FUN' is deprecated warning stream.
R CMD check --as-cran treats warnings-in-examples as errors.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Agent B
Summary
Replaces MorphyLib scoring in
TreeSearch(),Ratchet(),Jackknife()withnative C++ engine (
ts_fitch_score()), while retaining backward compatibilityfor users passing MorphyLib scorers explicitly.
New exports
PrepareNativeData()— replacesPhyDat2Morphy()CleanNativeData()— replacesUnloadMorphy()NativeLength()— replacesMorphyLength()NativeBootstrap()— replacesMorphyBootstrap()Changed defaults
TreeSearch,Ratchet,Jackknife, andEdgeListSearchnow default tonative scorers. New
concavityparameter (defaultInf= equal weights)makes implied-weights searches trivial:
Deprecations
PhyDat2Morphy,UnloadMorphy,MorphyLength,MorphyTreeLength,MorphyBootstrapemit.Deprecated()warnings.Vignette
custom.RmdIW section rewritten from ~150 lines of MorphyLib scaffoldingto ~30 lines.
Tests
7 new tests in
test-NativeSearch.R. Existing tests updated to use nativedefaults. 50 pass / 0 fail.
Note
Native scorer uses simple IW (
fit = e / (e + k)), matchingTreeLength(..., extended_iw = FALSE). XPIWE (Extension 3) remains in theC++ search path.