[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: numel(foo{:}) - feature or bug ?
From: |
Marco atzeri |
Subject: |
Re: numel(foo{:}) - feature or bug ? |
Date: |
Fri, 05 Aug 2011 19:06:42 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 5.1; rv:5.0) Gecko/20110624 Thunderbird/5.0 |
On 8/5/2011 6:37 PM, Sergei Steshenko wrote:
Oh, if somebody wants (pseudo)scientific terminology, then here it is:
Why does adding an element causes non-monotonicity in numel(foo2d{:}) ?
Thanks,
Sergei.
Sergei,
could you please cool down and trim a bit all your e-mails ?
It is not polite to report every time the full story of your
previous mails, and make following you very hard.
At least 2 persons already tried to explain you that fooo2d
and foo2d{:}) are not the same thing.
You can disagree on how numel works on matlab and octave, but or you
provide a compelling reason for the change and you provide also a
patch for the change, or I doubt numel will be modified.
by the way on GNU Octave, version 3.4.2
> foo
foo =
{
[1,1] = a
[2,1] = aa
[1,2] = b
[2,2] = [](0x0)
}
> foo(:)
ans =
{
[1,1] = a
[2,1] = aa
[3,1] = b
[4,1] = [](0x0)
}
> foo{:}
ans = a
ans = aa
ans = b
ans = [](0x0)
Please note the complete different answer !
> numel(foo)
ans = 4
> numel(foo(:))
ans = 4
> numel(foo{:})
ans = 0
> size(foo)
ans =
2 2
> size(foo(:))
ans =
4 1
> size(foo{:})
error: Invalid call to size. Correct usage is:
I supect you are thinking as foo(:) and foo{:} as equivalent
but they are not.
Regards
Marco
- Re: numel(foo{:}) - feature or bug ?, (continued)
Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
Re: numel(foo{:}) - feature or bug ?, Ben Abbott, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?, Jordi GutiƩrrez Hermoso, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
- Re: numel(foo{:}) - feature or bug ?,
Marco atzeri <=
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/06
- Re: numel(foo{:}) - feature or bug ?, Marco atzeri, 2011/08/06
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/06
- Re: numel(foo{:}) - feature or bug ?, Marco atzeri, 2011/08/06
- Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/06
Re: numel(foo{:}) - feature or bug ?, Jordi GutiƩrrez Hermoso, 2011/08/05
Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/05
Re: numel(foo{:}) - feature or bug ?, fork, 2011/08/05
Re: numel(foo{:}) - feature or bug ?, Sergei Steshenko, 2011/08/06