Textread can read only first column?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Textread can read only first column?

LucaLuca
https://gyazo.com/8b5ef70a4ed1c1c59cb1c1a5c79e8418

hi
i want to read with textread only che first column

[c,d,e,f,g,h]=textread (nomeFileDaEsaminare, "%s %f %f %f %f %f ");  => this
read all columns

[c]=textread (nomeFileDaEsaminare, "%s ");  ==> i try it but it  does not
work


exist another method? thank



--
Sent from: http://octave.1599824.n4.nabble.com/Octave-Maintainers-f1638794.html

Reply | Threaded
Open this post in threaded view
|

Re: Textread can read only first column?

mmuetzel
That should work when you add an asterisk in the formats you want to skip
(see "doc textread" which refers to "doc strread" for details):

c = textread (nomeFileDaEsaminare, "%s %*f %*f %*f %*f %*f ");


Markus



--
Sent from: http://octave.1599824.n4.nabble.com/Octave-Maintainers-f1638794.html