1

Suppose I have a script like this

set terminal png enhanced
set output "test.png"
set ytics format "%.1t 10^{%S}"
set ytics 5000
set mytics 5
set xrange [0:16000]
plot x

Which produces the following. Sample figure

I do wnat major tics as well as minor tics. However, the tic at zero looks ugly, so I would like to modify or delete it.

I tried set ytics (5000,10000,15000). This is possible, but then I loose the minor tics. Also, I don't want to put the tics manually.

So a solution to this problem would

  • remove the y=0 tic or
  • modify the set ytics format or
  • adds minor tics for manual major tics, but according to the manual this is not possible.

An other solution that I didn't think of is of course also appreciated!

Bernhard
  • 3,619
  • 1
  • 25
  • 50

1 Answers1

2

You can just overwrite the 0 tic with set ytics ('0' 0):

set ytics format "%.1t 10^{%S}"
set ytics 5000
set ytics add ('0' 0)
set mytics 5
set xrange [0:16000]
plot x

enter image description here

See also excluding a tic number in scientific format.

Community
  • 1
  • 1
Christoph
  • 47,569
  • 8
  • 87
  • 187
  • Thanks, I flagged my question as a duplicate, because I think the other question answers everything. However, I didn't find it earlier. – Bernhard Nov 08 '13 at 12:16