TABLE_IO
TABLE files
Read and Write Utilities
TABLE_IO is a MATLAB library,
using double precision arithmetic,
which can read or write a TABLE file.
A
TABLE file is a simple format for storing a double-indexed
array of data. We regard this is a situation involving N
points in M dimensions, with M relatively small
(often just 2 or 3, but possibly 10 or 20) while N can
be "enormous" (10, 100, 1,000 or 10,000).
To keep things simple, then, the data is written to an ASCII
file, with optional comment lines (which must start with the
'#' character) and blank lines (which are ignored). The point
data is stored by writing the coordinates of each point on
a separate line. No information about M or N is
explicitly included in the file.
It is up to the I/O program to determine this.
TABLE_IO supplies routines by which a TABLE file can
easily be written or read. A typical write operation simply
calls routine TABLE_WRITE. A typical read operation
will probably first want to call TABLE_HEADER_READ
to determine the values of M and N, and then
allocate space for the table, and then call TABLE_DATA_READ
to read the data.
Related Data and Programs:
TABLE
is a format used for the files input or output by the TABLE_IO library.
TABLE_IO is also available in
a C version and
a C++ version and
a FORTRAN77 version and
a FORTRAN90 version.
TABLE_LATINIZE
is a MATLAB program that can read in a TABLE file,
"latinize" it, and write out the new version.
TABLE_QUALITY
is a MATLAB program that can read in a TABLE file
and compute and print various measures of the quality of
dispersion of the point set.
TABLE_READ
is a MATLAB routine that can read in a TABLE file.
Source Code:
-
dtable_border_add.m,
adds a "border" to double precision table data.
-
dtable_border_cut.m,
cuts the "border" of double precision table data.
-
dtable_close_write.m,
closes a DTABLE file that was written to.
-
dtable_data_read.m,
reads a table from a double precision TABLE file.
-
dtable_data_write.m,
writes a table to a double precision TABLE file.
-
dtable_header_read.m,
reads a table header from a double precision TABLE file.
-
dtable_header_write.m,
writes a table header to a double precision TABLE file.
-
dtable_read.m,
reads a table from a double precision TABLE file.
-
dtable_write.m,
writes a table to a double precision TABLE file.
-
file_column_count.m,
counts the number of columns in the first line of a file.
-
file_row_count.m,
counts the number of row records in a file.
-
i4_log_10.m,
returns the integer part of the logarithm, base 10, of an integer.
-
i4mat_indicator.m,
sets up an indicator I4MAT.
-
i4mat_print.m,
prints an I4MAT.
-
i4mat_print_some.m,
prints some of an I4MAT.
-
itable_border_add.m,
adds a "border" to integer table data.
-
itable_border_cut.m,
cuts the "border" of integer table data.
-
itable_data_read.m,
reads a table from an integer TABLE file.
-
itable_data_write.m,
writes a table to an integer TABLE file.
-
itable_header_read.m,
reads a table header from an integer TABLE file.
-
itable_header_write.m,
writes a table header to an integer TABLE file.
-
itable_read.m,
reads a table from an integer TABLE file.
-
itable_write.m,
writes a table to an integer TABLE file.
-
r8_epsilon.m,
returns the R8 machine precision.
-
r8mat_indicator.m,
sets up an indicator R8MAT.
-
r8mat_print.m,
prints an R8MAT.
-
r8mat_print_some.m,
prints some of an R8MAT.
-
r8mat_transpose_print.m,
prints the transpose of an R8MAT.
-
r8mat_transpose_print_some.m,
prints the transpose of some of an R8MAT.
-
r8mat_uniform_01.m,
fills an array with pseudorandom numbers.
-
s_len_trim.m,
returns the length of a character string to the last nonblank.
-
s_word_count.m,
counts the number of words in a string.
-
timestamp.m,
prints the current YMDHMS date as a timestamp.
-
timestring.m,
returns a string containing the current YMDHMS date.
Examples and Tests:
-
table_io_test.m,
runs the tests.
-
table_io_test.out,
output from a run of the tests.
-
table_io_test01.m,
tests the routines that write a double precision TABLE dataset.
-
table_io_test02.m,
tests the routines that read a double precision TABLE dataset.
-
table_io_test03.m,
tests the routines that write an integer TABLE dataset.
-
table_io_test04.m,
tests the routines that read an integer TABLE dataset.
-
table_io_test05.m,
tests the routine that randomizes a double precision array.
-
table_io_test06.m,
tests ITABLE_BORDER_ADD and ITABLE_BORDER_CUT.
-
dtable_05_00020.txt,
the double precision table file created by the sample program, with
N = 20 points in M = 5 dimensions.
-
itable_05_00020.txt,
the integer table file created by the sample program, with
N = 20 points in M = 5 dimensions.
You can go up one level to
the MATLAB source codes.
Last revised on 27 September 2006.