help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: print resolution in latex


From: Reza Housseini
Subject: Re: print resolution in latex
Date: Mon, 16 Jan 2012 16:46:32 +0100

Hello Ben,
Thank you for the answer. I used the area plot function, here a small example:

Y = randn (4, 35040);

area(Y)
set(gca,"Layer","top")
grid on

print("test.tex","-dtex","-S1000,400");


So I want to stack the different vectors on each other and color the areas in between. With this approach however the files are large. Up to 5MB.
I just wondered if there is an technique to reduce the generated data, because in this way there's no use for a report due to much too large file sizes.

Reza

On Mon, Jan 16, 2012 at 2:40 PM, Ben Abbott <address@hidden> wrote:
On Jan 16, 2012, at 4:20 AM, Reza Housseini wrote:

> Hello Octave user,
>
> I try to print area plots with up to 35040 data points for the epslatex device. But the generated .ps file in latex is huge (7.5MB), due to the octave print output. I tried to adjust the resolution with the -r option but this didn't work. Is there any other way to reduce the file size without manually reduce my input vector? There's no need that I see all the details over the 35040 points, is just to get the reader an impression of how the data looks like.
>
> Thanks a lot for the support,
>
> Best wishes,
> Reza

Did you use the scattter() command to produce your plot ?  This command produces a patch object for each data point and can produce a very large file (and slow plot updates).

If you used that, you can try the plot command instead. Depending upon what you want that may take some extra effort, but you can start with ...

       x = randn (1, 35040);
       y = randn (1, 35040);
       h = plot(x, y, "s");
       set (h, "markerfacecolor", "auto")

Gnuplot's markers are  not implemented in a consistent way. So it may no display as expected, but if you print it, you will get the expected result.

       print -depsc test.eps

Using my example, the file size is 549 kB.

If my guess that you're using scatter() is not correct, please give us more information. If possible a simple script that demonstrates the problem would be helpful.

Ben


reply via email to

[Prev in Thread] Current Thread [Next in Thread]