olavolav / uniplot

Lightweight plotting to the terminal. 4x resolution via Unicode.
MIT License
370 stars 16 forks source link

Use different characters instead of colors #27

Closed AlbertoSinigaglia closed 4 months ago

AlbertoSinigaglia commented 6 months ago

Is is possible to use different characters instead of colors for plotting multiple series?

It would be nice because I use this library for plotting, and then redirect the python script output to a file, which obviously loses the concept of color, so using like "*" and "+" instead of colors you be nice

olavolav commented 6 months ago

Hi @AlbertoSinigaglia thanks for the suggestion!

This would be possible, but I imagine only for the force_ascii mode. At least it is less clear how to implement this using the default high-resolution mode via Unicode characters.

Is that what you mean, do you set force_ascii=True in the plots that you speak about?

AlbertoSinigaglia commented 6 months ago

Hi @AlbertoSinigaglia thanks for the suggestion!

This would be possible, but I imagine only for the force_ascii mode. At least it is less clear how to implement this using the default high-resolution mode via Unicode characters.

Is that what you mean, do you set force_ascii=True in the plots that you speak about?

Hi, thanks for the reply, yes, I actually use that flag to be sure to avoid compatibility issues

olavolav commented 4 months ago

@AlbertoSinigaglia With version v0.13.1 this is now possible. You can control the characters used with the force_ascii_characters option.