Checking Octave Variables

Description

Checks if an Octave object of a given name exists, using the Octave function exist.

Usage

o_exist(NAME, ...)

Arguments

NAME
name to check existence.
...
extra parameters passed to the Octave function exist.

Octave Documentation for <em>exist</em>

 -- Built-in Function: exist (NAME, TYPE)
     Return 1 if the name exists as a variable, 2 if the name is an
     absolute file name, an ordinary file in Octave's 'path', or (after
     appending '.m') a function file in Octave's 'path', 3 if the name
     is a '.oct' or '.mex' file in Octave's 'path', 5 if the name is a
     built-in function, 7 if the name is a directory, or 103 if the name
     is a function not associated with a file (entered on the command
     line).

     Otherwise, return 0.

     This function also returns 2 if a regular file called NAME exists
     in Octave's search path.  If you want information about other types
     of files, you should use some combination of the functions
     'file_in_path' and 'stat' instead.

     If the optional argument TYPE is supplied, check only for symbols
     of the specified type.  Valid types are

     "var"
          Check only for variables.

     "builtin"
          Check only for built-in functions.

     "file"
          Check only for files.

     "dir"
          Check only for directories.

     See also: file_in_loadpath

[Generated from Octave-3.6.4 on 2014-05-21 11:08:14 ]