6
\$\begingroup\$

I am using LTspice parametric sweeps to generate a series of different cases and plot waveforms and measured values. I have two sweep variables and 5-6 points for each variable. Now I want to see how my measured quantities (using .meas) vary with respect to the sweep variables.

Currently, when I want to figure out which line corresponds to which sweep variable value, I am looking at the colour preferences order. This becomes a bit troublesome when I have many sweep points.

Is there a way to include a legend in LTSpice graphs for a sweep variable? Of course, I can export the data and use some other tool to do all the further analysis. But here I am wondering if there is a way to make it easier with LTspice itself. (for waveforms, the solution provided by @aconcernedcitizen is very useful to group the results and display separately. But for measured quantities it does not work.)

\$\endgroup\$

3 Answers 3

9
\$\begingroup\$

Took me a while to figure out but yes, you can do this!

Right click the plot window. Select View > Step Legend.

View > Select Steps will let you change which plots are shown.

\$\endgroup\$
2
  • \$\begingroup\$ interesting. Although we cannot edit the legend, this does the job! \$\endgroup\$
    – Pojj
    Mar 18, 2021 at 18:30
  • 1
    \$\begingroup\$ Yea it also locks the graph, you can't zoom. \$\endgroup\$
    – Michael
    Mar 19, 2021 at 14:59
2
\$\begingroup\$

I don't believe there is a way to add a legend directly on the plot.

For me, the easier way to do this is to get a cursor on screen. Using the UP and DOWN arrow keys, you can shift between the different curves. If you move your mouse over the cursor, you should be presented with a "1" or a "2". When you see that, right click, and it will tell you which curve you are currently looking at.

\$\endgroup\$
2
  • \$\begingroup\$ Thanks, but when we have two sweep variables (therefore multiple lines), how can we directly find which line corresponds to which variable. Your suggestion is useful to see exact values at the measured points. \$\endgroup\$
    – Pojj
    Nov 12, 2019 at 8:14
  • \$\begingroup\$ @Pojj The info window will show which variables have which values. \$\endgroup\$ Nov 12, 2019 at 17:01
1
\$\begingroup\$

I'm not sure I understood corectly what you want, so if this is not the case, let me know so I can delete the answer.

When you make the waveform window active, you can select in the menu Plot Settings > Select Steps and you'll get table-like entries for your steps.

\$\endgroup\$
2
  • \$\begingroup\$ Thanks @aconcernedcitizen. But I was inquiring about graphs of measured quantities that are plotted from the error log. Select steps option is not active for those plots. your suggestion is very useful for understanding waveforms. Let me edit the question \$\endgroup\$
    – Pojj
    Nov 12, 2019 at 8:01
  • \$\begingroup\$ I only skimmed through @efox29's answer, so I only saw that he said the same thing after I posted, so I deleted my edits. \$\endgroup\$ Nov 12, 2019 at 16:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.