help-octave
[Top][All Lists]
Advanced

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

Re: MATLAB / Octave compatability, spacing, parsing


From: Paul Kienzle
Subject: Re: MATLAB / Octave compatability, spacing, parsing
Date: Thu, 27 Oct 2005 22:22:24 -0400


On Oct 27, 2005, at 3:49 PM, John W. Eaton wrote:

On 27-Oct-2005, Steve C. Thompson wrote:

| Also, something else. MATLAB doesn't support `printf'.
|
|   foo = 5;
|   printf('My result is: %d\n', foo)
|
| works in Octave, but not MATLAB.  If using MATLAB, the kludge
| is to issue `fprintf' instead:
|
|   foo = 5;
|   fprintf('My result is: %d\n', foo)

And of course Octave's fprintf is also equivalent to printf if the
first argument happens to be a character string.  Octave has printf
because it somehow seems wrong to me to use an f* function when there
is no file ID argument.

I wonder if we should have an mark_as_unavailable command to remove
a function from the non-system interface (i.e., unavailable from the
command line and from functions not in the system path)?  This would
allow someone to write a compatibility package which removes common
octave functions from consideration when working with colleagues who
use matlab.  Also, it would allow someone to set up a safe interpreter
for use in CGI scripts.

- Paul



-------------------------------------------------------------
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
-------------------------------------------------------------



reply via email to

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