On Oct 22, 2010, at 2:26 AM, Tobias Schmid wrote:
Am 21.10.2010 18:09, schrieb Ben Abbott:
On Oct 21, 2010, at 11:58 PM, Tobias Schmid wrote:
Am 21.10.2010 16:37, schrieb Ben Abbott:
On Oct 21, 2010, at 6:08 PM, Katzenman wrote:
Hello,
yes, that ist exactly what I'm looking for.
I just need to get a proper scaling for one plot.
An fontsize and type is not important, because I'm gonig to replace it,
using \psfrag in LaTex.
So for me it is just important to have a scaling, where there is no
overlapping of x/ylabel and x/yTicks.
And if it is possible to get a legende without overlapping labels, this
would be even better.
If that is not possible, I'll do it without using a legende and discribe the
curves in the caption of me figure in LaTeX.
Thanks for your help
Tobias
I had considered adding psfrag support to Octave. However, as psfrag is rather
dated and no longer maintained we decided not to add that support.
However, if you are interested in that functionality, I've attached the
function. This function works with the current developers sources. I haven't
tried it with the 3.2.x series, but I expect it will work.
Please let me know if it works well for you. Criticism is welcome.
Ben
Hello Ben,
I tried to use your code, but I got the error messages added below.
psfrag(Abbildung ,"test" ,'fontsize', 18 ,'height','\\psfragheight' , 'wid
th' , '\\psfragwidth')
error: mat2cell: dimension can not be empty
error: called from:
error: /home/tobias/Diplomarbeit/Octave/psfrag.m at line 342, column 15
error: /home/tobias/Diplomarbeit/Octave/psfrag.m at line 236, column 17
Did I forget to hand over the parameter dimension? In the help enty no
parameter called dimension in mentioned?
By the way, would this function solve my problem with the distances between the
labels and the entries of the legende , which are not scalable.
Tobias
I'll take a look at this tomorrow. In the meantime, does you plot have
ticklabels for each visible axes?
Ben
Yes, it does.
And as I told you, the tick labels and labels of the axes are overlapping, when
enlarging the fontsize.
You do not need to spend that much time on it. It's just one last plot for my
diploma thesis. And I didn't find a way to solve this problem on my own.
So, if you could explain to me, how to export the debug.gp file and modify it
in gnuplot to me, that would be great.
The psfrag thing already works fine with all my other plots.
I tried to modify the exported file, but if I'm honest, I couldn't even open it
in gnu plot.
So thanks for your help once again.
Tobias
Let me know what output format you prefer and I can modify these instructions.
Create your plot and output to a file.
plot (1:10)
xlabel ("xlabel")
ylabel ("ylabel")
drawnow ("pdf", "test.pdf", false, "debug.gp");
exit
Test the plotstream from the command line (DOS, BASH, other or shell).
gnuplot debug.gp
That will create (re-create) the file test.pdf. To be sure everything is
working, view it with ghostscript ...
gs test.pdf
You may need to replace "gs" with "gs.exe"
Edit debug.gp and look for "set terminal…" and edit that line to indicate the
fontname and fantsize. Notice you can also change the plot size.
set terminal pdf enhanced size 6,4 font "Helvetica,12"
Run gnuplot again …
gnuplot debug.gp
The result should look more proper.
gs test.pdf
If you like, email me the "debug.gp" file and I can look to see if there are
other problems. Theres been several changes to the plotstream Octave sends to gnuplot, so
I may have forgotten something important.
Ben