Repository navigation
ALDEx2 from a behavioural spec; R oracle agrees within MC noise (v0.2.0) - #4
Merged
Merged
Conversation
…tension; oracle harness (WIP: oracle not yet run) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
…roducible builder, DATASETS.md Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
…te Wilcoxon p too ALDEx2 1.42 calls round() on conds, which errors for a factor; it builds its own sorted factor, so a character vector gives the same level order. RCall's rcopy renames R's dotted columns (we.ep -> we_ep). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
The native and reference results disagreed beyond Monte-Carlo noise. This documents the two definitions behind that: the consistent-sign expected p and BH, and independent between/within pairing for the effect. It also records which reference source was read to diagnose it. Owner ruling: the code is re-derived from this document by an agent that has not read that source. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
… from the spec Re-implemented from docs/ALDEx2-SPEC.md by a separate agent that never had access to the reference source. Oracle (MC 512) now passes on all three datasets: native-vs-R is within R's own seed-to-seed noise on effect, Welch p and Wilcoxon p. Bump to 0.2.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
Contributor
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: ⛔ Files ignored due to path filters (4)
📒 Files selected for processing (22)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
… its error Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1
Contributor
|
Autopilot could not be updated. Open Coding to check access and billing. |
Signed-off-by: Jonathan D.A. Jewell <6759885+hyperpolymath@users.noreply.github.com>
hyperpolymath
added a commit
that referenced
this pull request
Oct 2, 2026
…re visible (#5) Main is red after #4 (run 37036456885). This fixes both failures. - **Agda proofs:** the merge of `main` into `feat/aldex2` kept #3's step name but put the old Agda 2.7.0.1 download step under it. `debian:13-slim` has no `curl`, so the job exited with code 127. The merge also dropped the checkout step. This PR restores #3's job (`76c1970`) verbatim. - **R reference oracle:** loading RCall exits with code 1 and prints nothing. The job now runs one step at a time: R loads ALDEx2, Julia starts R through RCall (with RCall's build log printed), and the extension loads. The comparison runs only after those pass. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1 --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
ALDEx2 (v0.2.0)
This adds two-group ALDEx2 (
aldex2) as native Julia, plus the RCall reference extension and an R oracle. The method is defined bydocs/ALDEx2-SPEC.md.What changed and why
The first native version, built from Fernandes et al. 2013/2014, disagreed with Bioconductor ALDEx2 1.42.0 by more than Monte-Carlo noise. On gut, the Welch p differed by 0.24 against R-vs-R noise of 0.066. On soil, the effect differed by 0.18 against noise of 0.03.
The causes were two definitions the papers leave open:
Provenance (clean-room)
aldex.ttest,t.fast,wilcox.fastandaldex.effect. No code was copied.87a6316, before any implementation.src/Methods/ALDEx2.jlfrom the spec. It had no access to the R library, could not deparse R functions, and could not search the web for the source. It confirmed it complied.c163e5f.Evidence
Pkg.test(): 55/55 pass. This covers P1/P5, P3 (CLR centring) and P6 (feature-relabelling equivariance), each with a planted mutant that the property kills.developer/logs/compositionalda-oracle-20261002d.log.On mock, the q<0.05 call sets are identical: mock1–5 on both sides.
Not proved
ALDEx2's calibration is tested against the reference, not proved. P3 and P6 are property-tested, not Agda-proved. See
proofs/PROOF-STATUS.md.Deliberate departure from the reference
The effect-size index permutations are drawn once and shared across features, where the reference draws them per feature. Each feature's marginal distribution is unchanged. Only the cross-feature correlation differs, and sharing is what makes P6 hold exactly.
Tested with Julia 1.12 (local) and the CI matrix 1.10/1.12, R 4.5.0, Bioconductor 3.22, and ALDEx2 1.42.0.
🤖 Generated with Claude Code
https://claude.ai/code/session_019Y6e175rh1LbrsEhQvCrJ1