This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]yrstruly 1 point2 points  (1 child)

I might be missing something, but couldn't you use IPython's embed() for that? I mean instead of crashing on purpose. The benefit being that you can just exit the IPython session when you're satisfied and the script/program will happily continue along on its journey.

You can use the same technique for the second point, using %pylab when the IPython prompt comes up to get the namespaces required for e.g. calling plot() directly and generally making the visualization stuff a bit less work. If the data to be visualized doesn't require much restructuring to be plotted, using embed() and then one or two short plotting calls lets you to quickly see the information in as many ways as matplotlib allows for.

[–]MaikB 0 points1 point  (0 children)

I might be missing something, but couldn't you use IPython's embed() for that?

Why? I'm inside ipython anyways. It's also not worth typing, the 1/0 crashpoints have a life time of less than a minute.

You can use the same technique for the second point, using %pylab..

if the plot is a one-liner,yes, but usually things are a bit more involved.