help-octave
[Top][All Lists]
Advanced

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

Print plot error


From: John B. Thoo
Subject: Print plot error
Date: Thu, 20 Aug 2009 13:45:53 -0700

Hi. I was using the script (see below) to print a sequence of plots as .png files so that I may create a movie using QuickTime Pro. Everything was going well until about half the plots had been printed, and I got the following error:

octave-3.2.0:36> makemovie
/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot: fork: Resource temporarily unavailable /Applications/Gnuplot.app/Contents/Resources/bin/gnuplot: line 67: / bin/gnuplot-4.2.5: No such file or directory
^C

octave-3.2.0:36>


What does this indicate?

A second question: It takes a while to draw each plot (x11) before it is printed. Is there a way to suppress the drawing, and only print the .png files from the data?


%% BEGIN SCRIPT
%% script name: makemovie.m

clf

filename = "muNegOne_ord7tf1";


wait = max (1/(tf - t0 + 1), 0.05);   % pause time between frames

lT = length (T) - 1;   % T = total number of plots saved in data file
N = 150; % number of time intervals (frames) to plot (must have N <= lT)

if (N > lT)
  error ('N > lT;  need  N <= lT');
end

time = ones (1, N);
time(2:N+1) = floor ((lT/N)*(1:N)) + 1;

for j = 1:N+1   % for "ode45"
  plot (x, u(:,time(j)));
  title (strcat ('time =', num2str ((tf-t0)*(time(j) - 1)/lT)));
  axis ([0 2*pi -1.5 1.5]);
%  axis([0 2*pi 2*min(real(u0)) 2*max(real(u0))]);
  print (sprintf ("./MakeMovie/%s%d.png", filename, j), "-dpng");
  pause(wait);
end

%% END SCRIPT

(Any suggestions to clean up my script would also be appreciated.)

I am using Octave 3.2.0 and gnuplot 4.2 patchlevel 5 on Mac OS X 10.4.11. Both Octave.app and Gnuplot.app were installed from Thomas Treichl's .dmg disc image into my Applications folder.

Thanks.

---John.


reply via email to

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