[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
axis & randn
axis & randn
Fri, 3 Nov 1995 00:29:00 -0600
Jerry Lynch <address@hidden> wrote:
: Just out of curiosity, are there any plans for some of the built-in
: functions to be updated in the next release of octave to resemble Matlab
For what it's worth, here are the new entries in the file since 1.1.1.
These are things that are already mostly done, but some items will
need addtional work.
* Expressions of the form
A(i,j) = x
where X is a scalar and the indices i and j define a matrix of
elements now work as you would expect rather than giving an error.
I am told that this is how Matlab 5.0 will behave when it is
* Indexing of character strings now works.
* The echo command has been implemented.
* New method for handling errors:
Where BODY and CLEANUP are both optional and may contain any
Octave expressions or commands. The statements in CLEANUP are
only executed if an error occurs in BODY.
No warnings or error messages are printed while BODY is
executing. If an error does occur during the execution of BODY,
CLEANUP can access the text of the message that would have been
printed in the builtin constant __error_text__. This is the same
as eval (TRY, CATCH) (which may now also use __error_text__) but
it is more efficient since the commands do not need to be parsed
each time the TRY and CATCH statements are evaluated.
* Octave no longer parses the help command by grabbing everything
after the keyword `help' until a newline character is read. To
get help for `;' or `,', now, you need to use the command
`help semicolon' or `help comma'.
* Built-in variables that can take values of "true" and "false" can
now also be set to any nonzero scalar value to indicate "true",
and 0 to indicate "false".
* If the new built-in variable `gnuplot_has_multiplot' is nonzero,
Octave assumes that your copy of gnuplot has the multiplot support
that is included in recent 3.6beta releases. It's initial value
is determined by configure, but it can be changed in your startup
script or at the command line in case configure got it wrong, or
if you upgrade your gnuplot installation.
* New built-in variable `warn_missing_semicolon'. If nonzero, Octave
will warn when statements in function definitions don't end in
semicolons. The default value is 0.
* Octave now attempts to continue after floating point excteptions
or out-of-memory errors.
* If Octave crashes, it now attempts to save all user-defined
variables in a file named `octave-core' in the current directory
* It is now possible to get the values of individual option settings
for the dassl, fsolve, lsode, npsol, qpsol, and quad functions
using commands like
dassl_reltol = dassl_options ("relative tolerance");
* The svd() function no longer computes the left and right singular
matrices unnecessarily. This can significantly improve
performance for large matrices if you are just looking for the
* The filter() function is now a built-in function.
* New function randn() returns a pseudo-random number from a normal
distribution. The rand() and randn() functions have separate
seeds and generators.
* Octave's command-line arguments are now available in the built-in
variable `argv'. The program name is also available in the
variables `program_invocation_name' and `program_name'. If
executing a script from the command line (e.g., octave foo.m) or
using the `#! /bin/octave' hack, the program name is set to the
name of the script.
* New built-in variable `completion_append_char' used as the
character to append to successful command-line completion
attempts. The default is " " (a single space).
* Octave now uses a modified copy of the readline library from
version 1.14.5 of GNU bash.
* New built-in variable `beep_on_error'. If nonzero, Octave will try
to ring your terminal's bell before printing an error message.
The default value is 0.
* New command-line argument --traditional sets the following
preference variables for compatibility with Matlab:
PS1 = ">> "
PS2 = ""
beep_on_error = 1
default_save_format = "mat-binary"
define_all_return_values = 1
do_fortran_indexing = 1
empty_list_elements_ok = 1
implicit_str_to_num_ok = 1
ok_to_lose_imaginary_part = 1
page_screen_output = 0
prefer_column_vectors = 0
prefer_zero_one_indexing = 1
print_empty_dimensions = 0
treat_neg_dim_as_zero = 1
warn_function_name_clash = 0
whitespace_in_literal_matrix = "traditional"
* New functions:
readdir -- returns names of files in directory as array of strings
mkdir -- create a directory
rmdir -- remove a directory
rename -- rename a file
umask -- set permission mask for file creation
stat -- get information about a file
lstat -- get information about a symbolic link
more -- turn the pager on or off
gammaln -- alias for lgamma
* New plotting functions from Vinayak Dutt. Ones dealing with
multiple plots on one page require features from gnuplot 3.6beta
bottom_title -- put title at the bottom of the plot
mplot -- multiplot version of plot
multiplot -- switch multiple-plot mode on or off
oneplot -- return to one plot per page
plot_border -- put a border around plots
subplot -- position multiple plots on a single page
subwindow -- set subwindow position for next plot
top_title -- put title at the top of the plot
zlabel -- put a label on the z-axis
* New function, fgetl. Both fgetl and fgets accept an optional
second argument that specifies a maximum number of characters to
read, and the function fgets is now compatible with Matlab.
* Printing in hexadecimal format now works (format hex). It is also
possible to print the internal bit representation of a value
(format bit). Note that these formats are only implemented for
* Additional structure features:
-- Name completion now works for structures.
-- Values and names of structure elements are now printed by
default. The new built-in variable `struct_levels_to_print'
controls the depth of nested structures to print. The default
value is 2.
-- New functions:
struct_contains (S, NAME) -- returns 1 if S is a structure with
element NAME; otherwise returns 0.
struct_elements (S) -- returns the names of all elements
of structure S in an array of strings.
* New io/subprocess functions:
XXX names of functions marked with `*' are subject to change
* async_system -- start a subprocess asynchronously
* execute -- start a subprocess with 2-way communication
mkfifo -- create a FIFO special file
popen -- open a pipe to a subprocess
pclose -- close a pipe from a subprocess
* sync_system -- start a subprocess synchronously
unlink -- delete a file
waitpid -- check the status of or wait for subprocesses
* New time functions:
asctime -- format time structure according to local format
ctime -- equivalent to `asctime (localtime (TMSTRUCT))'
gmtime -- return time structure corresponding to UTC
localtime -- return time structure corresponding to local time zone
strftime -- print given time structure using specified format
time -- return current time
The `clock' and `date' functions are now implemented in M-files
using these basic functions.
* New function getrusage returns a structure containing system
resource usage statistics. The `cputime' function is now defined
in an M-file using getrusage.
* If it is present, Octave will now use an `ls-R' database file to
speed up recursive path searching. Octave looks for a file called
ls-R in the directory specified by the environment variable
OCTAVE_DB_DIR. If that is not set but the environment variable
OCTAVE_HOME is set, Octave looks in $OCTAVE_HOME/lib/octave.
Otherwise, Octave looks in the directory $datadir/octave (normally
* Many more bug fixes.
* ChangeLogs are now kept in each subdirectory.