CommentedHeader

class astropy.io.ascii.CommentedHeader[source]

Bases: astropy.io.ascii.Basic

Character-delimited table with column names in a comment line.

When reading, header_start can be used to specify the line index of column names, and it can be a negative index (for example -1 for the last commented line). The default delimiter is the <space> character.

Example:

# col1 col2 col3
# Comment line
1 2 3
4 5 6

Methods Summary

read(self, table)

Read input data (file-like object, filename, list of strings, or single string) into a Table and return the result.

write_header(self, lines, meta)

Write comment lines after, rather than before, the header.

Methods Documentation

read(self, table)[source]

Read input data (file-like object, filename, list of strings, or single string) into a Table and return the result.

write_header(self, lines, meta)[source]

Write comment lines after, rather than before, the header.