help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

load from ascii files


From: Elliott Waldron
Subject: load from ascii files
Date: Thu, 4 Nov 2010 12:12:18 -0700 (PDT)

I have been using the load function with try/catch to test whether a file has
'load'able numeric data.
However, the load function will not throw an error if the line starts with
an 'n'.

e.g., 
  
octave:90> system('echo elliott > tmp.txt')
ans = 0
octave:91> load('tmp.txt')
error: load: failed to read matrix from file `tmp.txt'
octave:91> 
octave:91> system('echo niko > tmp.txt')
ans = 0
octave:92> load('tmp.txt')
octave:93> tmp
tmp = 0
octave:94> 

Is this by design? 

Thanks,

Elliott
-- 
View this message in context: 
http://octave.1599824.n4.nabble.com/load-from-ascii-files-tp3027605p3027605.html
Sent from the Octave - General mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]