Live data from Hacker News

Plotext – Python Plotting on the Terminal

github.com

11–20 of 27 posts

Re: Plotext – Python Plotting on the Terminal

#11
post #3

It is also possible to use kitty or other graphics capable terminal (iTerm2, mlterm etc) to show regular images inline when plotting from ipython3 or jupyter console (some extensions need to be installed).

Do you remember which extension?

This is one example https://github.com/grst/jukitty

I have some home made ones (working for kitty and mlterm/sixel etc), but they are not in shape for releasing.

ipython3 and jupyter console both have an image display hook you can use, but they work in different ways.

Re: Plotext – Python Plotting on the Terminal

#12
post #2

Looks nice, but when might it be needed?

Debugging, mainly. And really really dirty and fast workflows, when you don't have time to do pretty graphics.

The other thing is not depending on GUIs, libraries, and stuff, makes it resilient and usable in hard conditions (e.g. if you accidentally remove some core system libraries but you still want to see a graph)

Re: Plotext – Python Plotting on the Terminal

#17
post #3

It is also possible to use kitty or other graphics capable terminal (iTerm2, mlterm etc) to show regular images inline when plotting from ipython3 or jupyter console (some extensions need to be installed).

When using the Julia REPL I regularly use KittyTerminalImages [1], which is awesome because it fits perfectly with other plotting packages.

[1] https://github.com/simonschoelly/KittyTerminalImages.jl

Re: Plotext – Python Plotting on the Terminal

#19
Did you consider creating a backend for Matplotlib which rendered to ascii?? That way a matplotlib user could simply switch backends when on the terminal, and then switch to something else when the execution context changes. I don't know if that's even feasible, but that was what I first this was when I saw plt.

Re: Plotext – Python Plotting on the Terminal

#20
post #3

It is also possible to use kitty or other graphics capable terminal (iTerm2, mlterm etc) to show regular images inline when plotting from ipython3 or jupyter console (some extensions need to be installed).

When using the Julia REPL I regularly use KittyTerminalImages [1], which is awesome because it fits perfectly with other plotting packages. [1] https://github.com/simonschoelly/KittyTerminalImages.jl

Cool. The frontier for all of us is now to get screen and tmux to support it. Unfortunately it needs their buy-in (escapes/passthroughs don't work at all with scrollback)
Post reply on HN