[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: how to check if this exists
From: |
Stefan van der Walt |
Subject: |
Re: how to check if this exists |
Date: |
Sat, 4 Feb 2006 01:51:54 +0200 |
User-agent: |
Mutt/1.5.9i |
On Fri, Feb 03, 2006 at 05:56:40PM +0000, Corbin Champion wrote:
> If I create a variable x and x has an element
> x.name = "tom"
> if I do exist('x') I get a value of 1....good, but
> if I do exist('x.name') I get a value of 0 even though this exists.
Looks like x.name is not a variable, so I expect you are seeing the
result of
exist("tom")
Rather try
isfield(x, "name")
Regards
Stéfan
-------------------------------------------------------------
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
-------------------------------------------------------------