You can use msscanf function too
http://help.scilab.org/docs/5.4.0/en_US/mfscanf.html
sample :
//your data
dataIn = string(rand(500,500));
typeof(dataIn)
size(dataIn)
//convert to double
tic();
dataOut = matrix(msscanf(-1, dataIn, "%f"), size(dataIn));
disp("convertion time : " + string(toc()));
typeof(dataOut)
size(dataOut)
Antoine
Le 05/03/2013 11:09, Adrien Vogt-Schilb a écrit :
> hi
>
> my mistake
>
> the function name is csvTextScan
>
> http://help.scilab.org/docs/5.4.0/en_US/csvTextScan.html
>
> On 05/03/2013 11:06, Carrico, Paul wrote:
>> Thanks .. but is it in an Atoms package ? I failed in finding it on the web
>> site and the function seems not to be defined in Scilab (5.4.0)
>>
>> Paul
>>
>> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>> *De :* [email protected]
>> [mailto:[email protected]] *De la part de* A. Vogt-Schilb
>> *Envoyé :* mardi 5 mars 2013 10:12
>> *À :* International users mailing list for Scilab.
>> *Objet :* Re: [Scilab-users] Converting a matrix of string into real
>>
>> Hi
>>
>> csvStringtodouble
>>
>> Sent from my phone
>>
>> "Carrico, Paul" <[email protected]> wrote:
>>
>> Dear All
>>
>> After reading a text file (mgetl), removing the comments, I've finally a
>> matrix of string containing only numbers... what is the fastest way to
>> convert those string into reals (I don't remember)?
>>
>> using "eval" function is quite slow
>>
>> Thanks
>>
>> Paul
>> --------------------------------------------------------------------------------
>>
>>
>> Le présent mail et ses pièces jointes sont confidentiels et destinés à la
>> personne ou aux personnes visée(s) ci-dessus. Si vous avez reçu cet e-mail
>> par erreur, veuillez contacter immédiatement l'expéditeur et effacer le
>> message de votre système. Toute divulgation, copie ou distribution de cet
>> e-mail est strictement interdite.
>>
>> This email and any files transmitted with it are confidential and intended
>> solely for the use of the individual or entity to whom they are addressed.
>> If you have received this email in error, please contact the sender and
>> delete the email from your system. If you are not the named addressee you
>> should not disseminate, distribute or copy this email.
>>
>>
>>
>>
>> _______________________________________________
>> users mailing list
>> [email protected]
>> http://lists.scilab.org/mailman/listinfo/users
>>
>>
>
>
>
> _______________________________________________
> users mailing list
> [email protected]
> http://lists.scilab.org/mailman/listinfo/users
--
Antoine ELIAS
Software developer
-----------------------
Scilab Enterprises
143bis rue Yves Le Coz - 78000 Versailles
Phone: 01.80.77.04.70
http://www.scilab-enterprises.com
_______________________________________________
users mailing list
[email protected]
http://lists.scilab.org/mailman/listinfo/users