sfeam <
sf...@users.sourceforge.net> writes:
> Fab wrote:
>
>> Dear All
>>
>> I read in the Gnuplot info's, that when I define my own xtics, I can not
>> use mxtics, which makes sense.
>
> That's not quite right. You can define both tics and mtics manually.
> But you cannot define tics and have the program insert mtics automatically
> between them.
>
Indeed, I was not precise here!
>> However, especially in LaTeX terminals,
>> it is sometimes needed to redefine the axis label (actually only the
>> label and not the tics). Is it somehow possible to define xtics and
>> mxtics the usual way but then change only the axis label, leaving the
>> tics as they are?
>
> Certainly.
> set xtics ("One" 1, "Two" 2, "Three" 3)
> set xlabel "My favorite label"
>
> But maybe you are asking something else?
> For LaTeX output you often want to set a LaTeX format for the tic labels:
> set xtics format "$%g$"
>
My problem is the following: I have a plot with log x-axis. When I use
the format specifier for scientific notation, LaTeX will typeset this as
such (with the e-01, etc. notation). However, I would like to have xtic
labels like $10^{-1}$, hence I set them manually. But, for a log plot I
would also like the minor xtics to indicate the scale between the
decades. But I can not use xmtics in this case. Do I also have to
create an array for the minor xtics? I would like to have the xmtics
with half the ticlength of the major xtics. How would you do it?
>> E.g., in Matlab you have two arrays defining the
>> tics, one with the numeric data and the other with the label strings.
>
> That is also possible, so long as both arrays can be read from the
> same file:
>
> plot <my-real-plot>, 'labeldata' using 1:xticlabels(2)
>
> where the file labeldata contains
> 1 "One"
> 2 "Two"
> 3 "Three"
> ...
Thanks for this input!
Regards,
Fab