[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to keep print compatiable with MATLAB
From: |
David Bateman |
Subject: |
Re: How to keep print compatiable with MATLAB |
Date: |
Wed, 12 May 2004 10:48:04 +0200 |
User-agent: |
Mutt/1.4.1i |
According to Jianhong Wang <address@hidden> (on 05/12/04):
>
> 1. Is it possible to write one sentence of code to to
> change dir
> insteading if using micro define?
Write a script cd.m that is in your path for octave, but not matlab,
that contains something like
function cd (path)
## Find first : in path
idx = index (path, ":");
## Create valid path for cygwin
dir = strcat ("/cygdrive/", path(1:idx-1), path(3:end));
## Change directory
eval (["cd ", dir]);
endfunction
> 3. Is it possible to use legend( ) in Octave to show
> multiple legends
> like MATLAB?
What do you mean?
x = [1:0.1:10];
y = sin(x);
z = cos(x);
plot(x,y,'b');
hold on;
plot(x,z,'r');
legend ('Sin', 'Cos');
works fine in both matlab and octave....
D.
--
David Bateman address@hidden
Motorola CRM +33 1 69 35 48 04 (Ph)
Parc Les Algorithmes, Commune de St Aubin +33 1 69 35 77 01 (Fax)
91193 Gif-Sur-Yvette FRANCE
The information contained in this communication has been classified as:
[x] General Business Information
[ ] Motorola Internal Use Only
[ ] Motorola Confidential Proprietary
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------