![]() The result is that in Octave's still existing strread.m, which used to be called by (now removed) textscan.m, it works as follows:ġ. But I'm unsure if I have time for that the next days.įYI, I took up textscan.m / textread.m / strread.m some years ago and tried to make them as much Matlab-compatible as possible, based on a lot of observations of Matlab behavior at the time by me and several others, and given (Octave-)strread's limitations. On the other hand, a separate skip_eol() means that context can be kept out of the lower-level routines.Īnyway, there is another collection of textscan() bugs being sorted through at the moment, so we'll let the dust settle there and come back to this after some thought.īefore venturing further I think I might try similar tricks with whitespace and EOL settings in Matlab as I did in comment #12, with text and numeric data. But I think handling such a thing inside skip_whitespace() and skip_delim() makes for lots of conditional tests. "And then there is the thing that whitespace is treated differently when reading text, than when reading numeric data." ![]() And that's the reason I had to remove the skip_whitespace() from the skip_delim(), because otherwise it would remove the EOL. I believe there is currently a skip_whitespace prior to the scan action that does this. That is, the EOL-skip should be done prior to the scan action, not after. That's what I observed too, this was my goal for the modification. But when reading continues, endofline seems to be treated as leading whitespace (I have to confirm the latter)." ![]() "Maybe the only difference in the examples I gave is that regular delimiters after the last read field are skipped but just not endofline.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |