Hi. Today I can ask for this:
set yrange reverse
set y2range noreverse
set link y2 via y inverse y
Here I link y,y2 (to be equivalent). And I ask for a reversed y axis and a non-reversed y2 axis. This is impossible, but gnuplot doesn't complain, so unexpected things can happen in this situation. Can gnuplot warn or barf when given this? I think reasonable logic would be "if we have 'set link y2' then we can have 'set yrange' or 'set y2range', but not both".
Thanks
"set link" overrides previous settings and ranges. No error. That's just the way it is.
Hi. I don't think this is the case. I have this script:
set yrange [10:0]
set y2range [0:10]
set link y2 via y inverse y
set y2tics
plot x
If I remove one of "set yrange/y2range" commands, then the remaining one IS respected, despite the "set link" coming after. I.e. the "set link" doesn't override the existing setting. If I leave both "set yrange/y2range" in there, it's impossible to respect them both, and the "set y2range" is ignored.
I should better have said "set link keeps the current range of the primary axis, overriding whatever was previously in the secondary axis". Once the link is in place, autoscaling on either the primary or secondary axis affects both.