termgraph icon indicating copy to clipboard operation
termgraph copied to clipboard

disabling "cvt_to_readable"

Open ManiAm opened this issue 3 years ago • 2 comments

Is there any ways to disable "cvt_to_readable": Return the number in a human readable format

It produces wrong numbers,

    args = {
        "stacked": False,
        "width": 50,
        "no_labels": False,
        "format": "{:>5.2f}",
        "suffix": " minutes",
        "vertical": False,
        "histogram": False,
        "no_values": False,
        "different_scale": False
    }

    chart(colors=[TERM_GRAPH_AVAILABLE_COLORS['blue']],
          data=data,
          args=args,
          labels=labels)

2022-07-09_0-27-22

where data is:

[ [0.42475755214691163], [0.1093926469484965], [0.04674157698949178], [0.031145751476287842], ]

ManiAm avatar Jul 09 '22 07:07 ManiAm

I am having the same problem: essentially I have a file containing high precision numbers with many decimal places, and although the graph works correctly, the labels do not really show the numbers (or approximations thereof), rather conversions of them into some unit (as shown in the above screenshot).

I tried to specify the --format explicitly, but that only takes care of how many decimal places to carry with, leaving the display unit as they are.

This said, awesome library!

gennaro-tedesco avatar Aug 09 '22 19:08 gennaro-tedesco

+1 to this, would be very useful!

pelillian avatar Aug 19 '22 21:08 pelillian