Plots and variable inspection
RunMat Desktop keeps variables, command output, and figures together as you run code. Use the Variables view to examine computed values and the Plots view to work with 2D and 3D figures.
Inspect variables
The Variables view shows the workspace for the selected run. Each entry includes the variable's name, type, shape, and a compact preview when one is available.
Select a variable to open the full inspector. Scalars appear directly, while arrays, structures, and other values use inspectors suited to their type. Large arrays and GPU-resident values initially show a summary; Desktop loads additional data when you open or expand them.
Use the inspector to check:
- array dimensions and element types;
- scalar parameters and intermediate results;
- unexpected empty, missing, or nonfinite values;
- the values behind a plotted result.
You can also evaluate a small expression in the REPL when a result is easier to verify numerically. For example, check the range of an array, calculate an error norm, or confirm that a distribution integrates to the expected value.
Work with figures
Plotting functions open figures in the Plots view. Each figure appears in its own tab and updates when your program changes it. Available controls depend on the figure and can include pan, zoom, camera presets, reset, a details panel, maximization, and image copy or export.
Check axes, units, scales, labels, and legends before interpreting a figure. When the visual result looks wrong, inspect the corresponding workspace values to determine whether the issue comes from the computation or the plot.
By default, a new script run clears figures left by the previous run. You can change this under Settings > Advanced > Auto clear figures before script runs. Keep existing figures when your program intentionally updates figure handles across runs.
Review an earlier result
Select a completed run from run history to view the variables and figures saved with that run. This lets you compare results without replacing the active workspace.
Earlier results contain only the data captured when the run was saved. A variable or figure may be unavailable when its value was omitted, its type cannot be restored, or a saved artifact is missing. See Run history and replay for capture, retention, and replay behavior.
Verify a result
A figure presents values computed by your program. Use the Variables view or REPL to check important results directly. For example, confirm that a probability distribution integrates to 1 or that a displacement has the expected magnitude and units.
Save the run or notebook when you want to revisit its output, variables, and figures later. Rerun the project from its normal entrypoint when you need to confirm that the result does not depend on workspace state left by earlier commands.
Troubleshooting
- No variables appear: confirm that the selected run completed and produced workspace values. For an earlier run, check whether its workspace was captured.
- No figure appears: review command output for plotting errors and confirm that the selected run reached the plotting call.
- The figure is from an earlier run: select the intended run, or enable automatic figure clearing before script runs.
- A saved figure is unavailable: inspect the run's numerical values and rerun the source to recreate the figure.
- Figure interaction is slow: reduce the amount of displayed data or the complexity of the scene.
For Runtime-level plotting behavior and supported functions, see Plotting.