User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

filesize [2010/06/22 04:59] (current)
jochen created
Line 1: Line 1:
 +====== filesize (reference only) ======
 +<​file> ​ filesize ​ - return a file's size in bytes
 +  FORMAT: ​      fsz = filesize(filename)
 +  Input fields:
 +        filename ​   filename
 +  Output fields:
 +        fsz         ​filesize
 +  Note: returns NaN if the file doesn'​t exist</​file>​
 +===== Notes =====
 +This function uses Matlab'​s internal ''​dir''​ function instead of reading the file. This means that this number is only valid for files that are not in use when written to. In some cases the filesystem reports an incorrect size (e.g. some operating systems report a size of 0 for files that have not been flushed yet while they are written)!
filesize.txt ยท Last modified: 2010/06/22 04:59 by jochen