energy-diagram¶
Draw a state energy diagram directly from numeric values you provide — it does not read structure files and runs no quantum / thermo / MLIP calculations (--thermo / --dft). Use it when numeric state energies are already known (e.g. from summary.json) and only the formatted diagram is needed. It produces one image file and an optional machine-readable sidecar.
Examples¶
# Command form
pdb2reaction energy-diagram -i VALUES... [-o OUTPUT] [--label-x...] [--label-y...]
# List string (recommended for ad-hoc plots)
pdb2reaction energy-diagram -i "[0, 12.5, 4.3]" -o energy.png
# Repeated flag form (use one `-i` per value)
pdb2reaction energy-diagram -i 0 -i 12.5 -i 4.3 -o energy.png
# X/Y labels — same applies to --label-x / --label-y
pdb2reaction energy-diagram -i "[0, 12.5, 4.3]" \
--label-x "['R','TS','P']" --label-y "ΔE (kcal/mol)" -o energy.png
Workflow¶
Collect values from
-i/--input(supports repeated flags and a single list-like string).Parse all input values as floats and fail early if fewer than two values are provided.
Parse optional
--label-xvalues. If omitted, labels are auto-generated asS1,S2,…Validate label count (
--label-x) against value count, then render the diagram.Save the image to
-o/--outputand print the saved path.
Outputs¶
OUTPUT.(png|jpg|jpeg|svg|pdf)
result.json # Optional sidecar with status, n_points, files plus standard envelope fields (command/version/schema/environment); no per-point energies or labels (when --out-json is set)
If
-o/--outputis omitted,energy_diagram.pngis written to the current directory.When output has no extension,
.pngis appended automatically.Parent directories are created automatically when needed.
CLI options¶
Option |
Description |
Default |
|---|---|---|
|
Numeric values (multiple args or list-like string). |
Required |
|
Output image path ( |
|
|
X-axis state labels. Count must match input value count. |
|
|
Y-axis label. |
|
|
Write a machine-readable |
|
The full flag list is in the generated command reference.
Notes¶
Input order is used directly as plotting order.
At least two numeric values are required.
See Also¶
Common Error Recipes – Symptom-first failure routing
Troubleshooting – Detailed troubleshooting guide
trj2fig – Plot profile from trajectory energies
all – End-to-end workflow with built-in energy diagram output