Ben,
Ok, I found the problem.
As I see it, when set(gca,'box','off') is executed, the stream to gnuplot adds
> unset y2tics; set ytics in nomirror
> unset x2tics; set xtics in nomirror
> set border 3;
The last line is the problem. With this I see that box off in octave
means "axes in the left-botom margins".
I see three possible solutions:
1. Make set(gca,'box','off') deal with the current state of axis.
2. Make set(gca,'box','off') be gnuplot's "unset border"
3. Make set(gca,'yaxislocation','zero') be gnuplot's "set yzeroaxis;
set border 1; "
Make set(gca,'xaxislocation','zero') be gnuplot's "set xzeroaxis;
set border 2; "
Thanks