[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: line continuations
From: |
José Abílio Matos |
Subject: |
Re: line continuations |
Date: |
Thu, 20 Feb 2020 16:49:43 +0000 |
On Thursday, 20 February 2020 14.35.19 WET Nicholas Jankowski wrote:
> can you give a code example of what produces an error in matlab but not
> octave? i may be misunderstanding your earlier comments.
c = ['1 2 3 '; '4 5 6 ']
strrep(c, '2', '0')
The call to strrep fails in Matlab since c is not a char array and it succeeds
in Octave (with an anti-intuitive result IMHO). My proposal is to do the same
in Octave.
[m,n] = size(c);
If m != 1 and n!= 1 then throw an error. I hope that this now makes sense. :-)
Regards,
--
José Matos
- Re: line continuations, Rik, 2020/02/19
- Re: line continuations, José Abílio Matos, 2020/02/19
- Re: line continuations, Nicholas Jankowski, 2020/02/19
- Re: line continuations, José Abílio Matos, 2020/02/20
- Re: line continuations, Nicholas Jankowski, 2020/02/20
- Re: line continuations,
José Abílio Matos <=
- Re: line continuations, Nicholas Jankowski, 2020/02/20
- Re: line continuations, José Abílio Matos, 2020/02/20
- Re: line continuations, Nicholas Jankowski, 2020/02/20
- Re: line continuations, José Abílio Matos, 2020/02/20