Repository navigation
Fix print() for Wiener/RT-choice estimates without a Component column - #681
Merged
Merged
Conversation
Co-authored-by: DominiqueMakowski <8875533+DominiqueMakowski@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix print method for estimate means and contrasts
Fix print() for Wiener/RT-choice estimates without a Component column
Oct 14, 2026
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
DominiqueMakowski
marked this pull request as ready for review
October 14, 2026 20:54
DominiqueMakowski
approved these changes
Oct 14, 2026
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Regression tests are missing for both corrected printing failures.
1 open finding
What changed in this PR
Fixes printing failures for Wiener and RT-choice estimates in the shared printer, addressing #680.
Changes:
- Uses regular formatting when
Componentis absent. - Avoids invalid column removal when only one component remains.
| File | Description |
|---|---|
| R/print.R | Guards component-specific formatting and single-component column removal. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+110
to
+112
| if ( | ||
| (isTRUE(attr$model_info$is_wiener) || isTRUE(attr$model_info$is_rtchoice)) && | ||
| "Component" %in% colnames(x) |
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.

For
is_wiener/is_rtchoicemodels, everyprint()method went to.print_drift_diffusion(), which splits the table byComponent. Only response predictions have that column, so printing estimates of a distributional parameter (predict = "mu","bs") failed..print_drift_diffusion()also failed when only one component was left, e.g. after subsetting.Changes
print.estimate_contrasts()(R/print.R)Componentcolumn. Tables without one use the regular formatting path..print_drift_diffusion()(R/print.R)setdiff(names(out), i)is empty. With a single component,out[[i]][[character(0)]] <- NULLthrew an error.No tests,
NEWS.mdentry or version bump are included yet.print()fails forestimate_means()/estimate_contrasts()on Wiener and RT-choice models #680