Histogram Plots: Implement Show Plot Data - #14359
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR completes the “Show Plot Data” functionality for histogram plots by implementing RimHistogramPlot::asciiDataForPlotExport() (previously a stub) and making the command available from the histogram plot widget’s context menu.
Changes:
- Implemented histogram ASCII export by recomputing each visible curve with the current frequency type and emitting one tab-separated row per bin (bin center + frequency).
- Ensured export output is independent of render graph type by computing with
LINE_GRAPHto avoid duplicated edge values from bar/step outlines. - Added
RiuContextMenuLauncherto the histogram plot widget and removed the unused histogram-export helper declaration.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| ApplicationLibCode/ProjectDataModel/Histogram/RimHistogramPlot.h | Removes unused histogram-export helper declaration and an unused include. |
| ApplicationLibCode/ProjectDataModel/Histogram/RimHistogramPlot.cpp | Implements histogram plot ASCII export and adds “Show Plot Data” to the plot widget context menu. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
magnesj
force-pushed
the
histogram-show-plot-data
branch
from
July 27, 2026 08:51
1407f49 to
8e3ee05
Compare
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.
Fixes #14360
"Show Plot Data" for histogram plots opened an empty text window, as
RimHistogramPlot::asciiDataForPlotExport()was an unimplemented stub. In addition, the command was not available when right-clicking inside the plot widget.Changes:
asciiDataForPlotExport()for histogram plots. For each visible curve, the export contains the curve name, a header row and one tab-separated row per bin (bin center and frequency). The values are computed from the curve's data source with the plot's current frequency type, so the exported numbers match what is plotted.asciiDataForHistogramPlotExport( DateTimePeriod, bool )helper. The parameters were copied from the summary plot equivalent and have no meaning for histograms.RiuContextMenuLauncherwithRicShowPlotDataFeatureto the histogram plot widget, following the same pattern as correlation, analysis and VFP plots.RifCsvDataTableFormatterusing tab as field separator, so the text can be pasted into Excel with bin centers and frequencies in separate columns.Example output: