Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

pm3d epslatex axis labels too close to axes

280 views
Skip to first unread message

Gernot Hassenpflug

unread,
Feb 15, 2007, 11:22:19 PM2/15/07
to
Since I have been using the 4.2-rc4 version my epslatex output has
been much more reliable, thank you very much. Mr. Mikulik urged me to
post any perceived bugs, and since the OP in another thread has not
done so, apparently, I take it upon myself.

In epslatex mode, tick marks for the x and y axes are too close to the
axis lines, and often overlap these. Furthermore, the x-axis
lower-boundary mark may overwrite the z-axis lower-boundary mark.

Below is an example adapted from Mr. Matsuda's page.

A workaround for the unsightly spacing I can think of are:
1. specify axis tick marks explicity to avoid lumping
2. ensure no tick label for edges of axes

But I cannot see a way to control the spacing between the labels and
the axis.

Many thanks for any input,
Gernot Hassenpflug

set term epslatex solid color
set output "check.tex"
set pm3d explicit
set palette rgbform 9,8,9
set parametric
set urange [0:2*pi]
set vrange [-pi:pi]
set isosamples 36,24
set hidden3d
set view 75,35,1,1
unset key
set ticslevel 0
x1(u,v)=cos(u)+.5*cos(u)*cos(v)
y1(u,v)=sin(u)+.5*sin(u)*cos(v)
z1(u,v)=.5*sin(v)
x2(u,v)=1+cos(u)+.5*cos(u)*cos(v)
y2(u,v)=.5*sin(v)
z2(u,v)=sin(u)+.5*sin(u)*cos(v)
splot x1(u,v), y1(u,v), z1(u,v) w pm3d, \
x2(u,v), y2(u,v), z2(u,v) w pm3d
splot x1(u,v), y1(u,v), z1(u,v) lt 3,\
x2(u,v), y2(u,v), z2(u,v) lt 5
unset output
set term pop

--
BOFH excuse #437:

crop circles in the corn shell

Ethan Merritt

unread,
Feb 16, 2007, 4:57:46 PM2/16/07
to
In article <871wkq7...@fukaolx15.rish.kuins.net>,

Gernot Hassenpflug <ger...@mb3.seikyou.ne.jp> wrote:
>Since I have been using the 4.2-rc4 version my epslatex output has
>been much more reliable, thank you very much. Mr. Mikulik urged me to
>post any perceived bugs, and since the OP in another thread has not
>done so, apparently, I take it upon myself.
>
>In epslatex mode, tick marks for the x and y axes are too close to the
>axis lines, and often overlap these. Furthermore, the x-axis
>lower-boundary mark may overwrite the z-axis lower-boundary mark.

>I cannot see a way to control the spacing between the labels and
>the axis.

I think that is a general problem in splot, not specific to the
epslatex terminal. The tic label offsets are ignored in 3D.
This should probably be fixed, but in the meantime you can work
around this by using the tic label format statement. For instance,
your example plot looks better if you add the commands

set format x "\n %g"
set format y "\n%g"


--
Ethan A Merritt

Ethan Merritt

unread,
Feb 16, 2007, 5:06:17 PM2/16/07
to
In article <er59cq$ld$1...@brogar.bmsc.washington.edu>,
Ethan Merritt <mer...@u.washington.edu> wrote:
>In article <871wkq7...@fukaolx15.rish.kuins.net>,

>
>
>The tic label offsets are ignored in 3D.
>This should probably be fixed, but in the meantime you can work
>around this by using the tic label format statement. For instance,
>your example plot looks better if you add the commands
>
> set format x "\n %g"
> set format y "\n%g"


Sigh. Brain not working today.
The tic label offsets are not ignored in 3D. But the verical
offset is still "y", not "z". So to displace your
tic labels downwards, away from the axis lines:

set xtics offset 0,-0.5
set ytics offset 0,-0.5

--
Ethan A Merritt

Gernot Hassenpflug

unread,
Feb 18, 2007, 7:07:27 AM2/18/07
to
>>>>> "Ethan" == Ethan Merritt <mer...@u.washington.edu> writes:

Ethan> In article <er59cq$ld$1...@brogar.bmsc.washington.edu>,


Ethan> Ethan Merritt <mer...@u.washington.edu> wrote:
>> In article <871wkq7...@fukaolx15.rish.kuins.net>,

/../
Ethan> Sigh. Brain not working today. The tic label offsets are
Ethan> not ignored in 3D. But the verical offset is still "y", not
Ethan> "z". So to displace your tic labels downwards, away from
Ethan> the axis lines:

Ethan> set xtics offset 0,-0.5 set ytics offset 0,-0.5

Many thanks, that works fine for me.
--
G Hassenpflug

0 new messages