[Scilab-users] Generating a boolean vector or matrix

Federico Miyara fmiyara at fceia.unr.edu.ar
Thu Sep 5 09:35:31 CEST 2019



On 05/09/2019 04:13, Stéphane Mottelet wrote:
>
> Le 05/09/2019 à 08:55, Lamy Alain a écrit :
>
>> Hi,
>>
>> I’m not convinced the new syntax: ones(n, m, “boolean”) is a good 
>> idea or is necessary because it makes “integer” (“constant”) and 
>> “boolean” 2 identical types.
>>
> Sorry Alain can you explain it further ?
>>
>> There is a simple way to do the same :
>>
>> repmat(%t, n, m)
>>
> Yeah, there are many other (ineficient) ways, but the average user 
> would appreciate to have one and only one function (here "zeros") to 
> initialize a matrix regardless is type.
>


Yes, that is exactly the use case!

Federico Miyara




---
El software de antivirus Avast ha analizado este correo electrónico en busca de virus.
https://www.avast.com/antivirus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20190905/e5f03758/attachment.htm>


More information about the users mailing list