Contents Previous Next Subchapters

Reading Files with a Specified Data Value Separator
Syntax read(filemtypenrncnSkipseparator)
See Also read(file, mtype) , read(file, mtype, nr, nc, nSkip) , bread(file)

The argument separator must be a character scalar which specifies a character in addition to the default white space characters for separating values of input. O-Matrix always treats spaces and tabs as value separators when reading text files. The argument separator is used in addition to space and tab as a value delimiter.

If you have sample data file sample.dat that contains
     Sample Data
and you enter,
     file = "sample.dat"
     read(file, "real", 2, 3, 1, ";")
O-Matrix will respond,
     [ 1.1 , 1.2 , 1.3 ]
     [ 2.1 , 2.2 , 2.3 ]