help-octave
[Top][All Lists]
Advanced

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

Re: is_scalar conflicts with isstring


From: SZABO Sandor
Subject: Re: is_scalar conflicts with isstring
Date: Tue, 06 Mar 2001 15:14:25 +0100

Johan Kullstam wrote:

> SZABO Sandor <address@hidden> writes:
>
> > Hello,
> >
> > The behaviour of is_scalar conflicts with isstring.
> > Namely,
> > >> a="azez"
> > a = azez
> > >> length(a)
> > ans = 4
> > >> is_scalar(a(1))
> > ans = 1
> > >> isstr(a(1))
> > ans = 1
> >
> > Why don't give  is_scalar(a(1))  the  0 value?
> > I use Octave 2.0.16 .
>
> jk:1> a="ayez"
> a = ayez
> jk:2> a(1)
> ans = a
>
> hmm a(1) looks scalar to me.  it's only the first letter.
>
> --
> J o h a n  K u l l s t a m
> address@hidden
>

I see. So my question is:
Does exist a function, say, is_number
for which
is_number(s)
 Return 1 if  s  is a number (real or complex, in any format)?

Sandor Szabo



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