[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #37023] strread with leading white space in ne
From: |
Philip Nienhuis |
Subject: |
[Octave-bug-tracker] [bug #37023] strread with leading white space in new lines |
Date: |
Tue, 14 Aug 2012 09:53:08 +0000 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.11) Gecko/20100701 SeaMonkey/2.0.6 |
Update of bug #37023 (project octave):
Status: None => Confirmed
Assigned to: None => philipnienhuis
Operating System: Microsoft Windows => Any
_______________________________________________________
Follow-up Comment #1:
(Sorry for late reply, I'm on vacation abroad w/o much Internet access)
The example file you posted contains an empty line. Is that correct?
When I interpret your datafile as
" 1. 1 \n 2 3\n"
I get:
octave-3.6.2.exe:13> data = textscan(" 1. 1 \n 2 3\n", '%f %f')
data =
{
[1,1] =
1
NaN
3
[1,2] =
1
2
}
...which indeed looks suspicious. I'll have a look at it in the next weeks.
As a workaround, you can also specify the "whitespace" parameter:
octave-3.6.2.exe:14> data = textscan(" 1. 1 \n 2 3\n", "%f %f",
"whitespace", "")
data =
{
[1,1] =
1
2
[1,2] =
1
3
}
Thanks for the report.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?37023>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/