1

Using gnuplot v4.6.6: To increase the available space for the actual graph I want to reduce the space required by the y-axis label to the bare minimum.

I'm now using: set format y "%4.1s%c".
Which results in labels like 500.0k. It would be nice if I could reduce this by one more character resulting in labels that look like this : 500k0

However, I can't figure out how to get this. Can it be done, and if so: how?

Thanks for your help.

EDIT: Here's an example graph of what I have now: example For this graph I use set format y "%3.0s%c" which is okay most of the time. But in some cases an extra decimal would be helpful.

11
  • Who not just make the graph bigger? Commented May 14, 2016 at 19:21
  • The graph is now 1280x320. Increasing it will mean that it won't fit on screen or paper and would need to be scaled down. Effectively destroying the resolution. Commented May 14, 2016 at 20:49
  • Don't use a pixel-based output format. Use a vector-based format instead. It's hard to recommend a format without knowing how you want to use the graph, but consider using e.g. the pdfcairo or svg terminals. For webpages also check out the canvas terminal. Commented May 14, 2016 at 20:55
  • canvas produces images 4x bigger than png. svg and pngcairo produces images 2x bigger. pdfcairo is almost 50x bigger. I don't see how changing the terminal is going to answer my question. Commented May 22, 2016 at 9:26
  • What do you mean by bigger in this context? Commented May 22, 2016 at 11:43

1 Answer 1

2

You can modify the decimal character:

set decimalsign 'k'

Update:

Or you could plot log10(bits/s);

set yrange[0:9]
set ytics 1
plot 'data.d' using 1:(log10($2))

That would represent everything between 0 bits/s and 10^9 bits/s with a single digit on the y axis...

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.