Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.graphics.apps.gnuplot > #2954

Re: auto caluclation for data display

From Jörg Buchholz <bookwood4new@freenet.de>
Newsgroups comp.graphics.apps.gnuplot
Subject Re: auto caluclation for data display
Date 2015-06-23 08:53 +0200
Organization Universitaet Hannover
Message-ID <mmavor$c8s$1@newsserver.rrzn.uni-hannover.de> (permalink)
References (1 earlier) <mlv6o7$6hf$1@dont-email.me> <mm8c4v$iqg$1@newsserver.rrzn.uni-hannover.de> <mm9208$q3t$2@solani.org> <mm9fbn$stp$1@dont-email.me> <curavsFend1U1@mid.dfncis.de>

Show all headers | View raw


On 22.06.2015 22:54, Hans-Bernhard Bröker wrote:
> Am 22.06.2015 um 19:08 schrieb Jörg Buchholz:
>
>> At a simple plot the y-labels are 10ki, 20ki, 29ki ...
>> Why the step from 20 to 29?
>
> Because you selected mismatched options for the axis tic step and the
> tick label format.  One is in powers-of-ten, the other is in powers-of-two.
>
>> If I use set format y "%.b %BB" I've get 10kiB, 20kiB ....
>> Is it possible to change the "i"?
>
> No, because omitting it would be wrong.  ISO standard power-of-1024
> prefixes have an 'i' to distinguish them from power-of-1000 prefixes.
> See https://en.wikipedia.org/wiki/Binary_prefix for the details. Without
> them, the output would be just as brutally wrong as all the abusers of
> decimal prefixes for binary powers have been over the years.
>
> Strictly speaking "ki" is wrong, too.  It should be "Ki".

Thanks a lot to you and Karl for this informations. Now I have read a 
lot about the Mb and MiB confusion.
If I understand it correct than, if the original data are in byte, than 
data/1024^2 gives me data in MiB and not in MB.

Or say it with "gnuplot"

if (STATS_max_y >= 1024**2) {
set ylabel "Data Downloaded in MiB"
plot "data.txt" using 1:($2/1024**2) with boxes lc "green" title "Daily 
Usage",\
"data.txt" using 1:($2/1024**2):(sprintf("%.0f",$2/1024**2)) with labels 
offset 0,1

is a correct part of my previous "if - else script"

To me the if-else version has more options than use the format-specifers 
%b %B. So I can change the y-label, the color, etc.

Kind regards

Jörg

Back to comp.graphics.apps.gnuplot | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

auto caluclation for data display Syed Jahanzaib <aacable79@gmail.com> - 2015-06-18 05:01 -0700
  Re: auto caluclation for data display Jörg Buchholz <bookwood4new@freenet.de> - 2015-06-18 21:40 +0200
    Re: auto caluclation for data display Jörg Buchholz <bookwood4new@freenet.de> - 2015-06-22 09:06 +0200
      Re: auto caluclation for data display Karl Ratzsch <mail.kfr@gmx.net> - 2015-06-22 15:19 +0200
        Re: auto caluclation for data display Jörg Buchholz <bookwood4new@freenet.de> - 2015-06-22 19:08 +0200
          Re: auto caluclation for data display Karl Ratzsch <mail.kfr@gmx.net> - 2015-06-22 22:47 +0200
            Re: auto caluclation for data display Karl Ratzsch <mail.kfr@gmx.net> - 2015-06-22 22:58 +0200
          Re: auto caluclation for data display Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2015-06-22 22:54 +0200
            Re: auto caluclation for data display Jörg Buchholz <bookwood4new@freenet.de> - 2015-06-23 08:53 +0200

csiph-web