Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: textread/textscan not reading formatted text with whitespace
Replies: 19   Last Post: Oct 22, 2013 5:13 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Norbert Marwan

Posts: 7
Registered: 10/2/13
Re: textread/textscan not reading formatted text with whitespace
Posted: Oct 2, 2013 3:15 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

dpb <none@non.net> wrote in message <l2hjad$476$1@speranza.aioe.org>...
>
> One would think it should be a bug indeed but unfortunately it isn't. :(
>

why not?
in my opinion this is a bug when it is not working as it should do. i do not see any reason why the whitespace should not be counted when using the format strings.

> The only choice is to do one of the following --
>
> a) If possible create the file as delimited rather than fixed width

unfortunately not possible.

> b) Read the file in as a single char array and do a global substitution
> to insert a delimiter then parse the result from memory

this is what i finally did. but this is not an elegant solution. and it is not as fast as textread would be.
>
> e) Write a Fortran mex file to parse the file and return it to Matlab
> using Fortran fixed-width fields (or, as long as there are not empty
> fields, list-directed i/o works as well).

too much work for such a simple problem.
>
> I would urge you to add to the clamor by requesting TMW fix this
> oversight/shortcoming by submitting formal feature request to support at
> the mathworks.com site. (This has been one of my pet peeves for 20+ yr
> as regulars at cs-sm will attest :) )

i have sent a request to the matlab support. let's see what they answer.

thank you veryy much for the quick reply!


Date Subject Author
10/2/13
Read textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
Derek Goring
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/3/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/3/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/2/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/3/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/3/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
Norbert Marwan
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb
10/22/13
Read Re: textread/textscan not reading formatted text with whitespace
dpb

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.