[Scilab-users] Extracting strings to a matrix

Станислав krotersv at gmail.com
Thu Mar 7 16:53:44 CET 2013


07.03.2013 20:31, samuel.enibe at unn.edu.ng пишет:
> Dear sir,
> Suppose I have the matrix shown below.
>
> Names = ['samuel Ogbonna Enibe',
>                 'James Peter';
>                  'WIlson Stone Wilberforce Joshua';
>                  'Moses'];
> I would like to extract the matrix  from Name into a new matrix Namenew such that the first words are placed in the first column, second words in the second column, third words in the third column, etc.
>
> I know one solution is to save the data in a text file and extract it again using space as column separator.
>
> What is the simpler way of creating my new matrix Namenew.
>
> Samuel Enibe
>
> Sent from my Nokia phone
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users
Hi.
I think you can use *strtok*.

Stanislav
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20130307/2b2aa173/attachment.htm>


More information about the users mailing list