astro py:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- Astropy v0.3 »
- ASCII Tables (`astropy.io.ascii`) »
- FixedWidthNoHeader

# FixedWidthNoHeader

class `astropy.io.ascii.fixedwidth.``FixedWidthNoHeader`(col_starts=None, col_ends=None, delimiter_pad=' ', bookend=True)

  Bases: `astropy.io.ascii.fixedwidth.FixedWidth`

  Read or write a fixed width table which has no header line. Column names are either input (`names` keyword) or auto-generated. Column positions are determined either by input (`col_starts` and `col_stops` keywords) or by splitting the first data line. In the latter case a `delimiter` is required to split the data line.

  Examples:

      # Bar delimiter in header and data

      |  1.2  | hello there |     3 |
      |  2.4  | many words  |     7 |

      # Compact table having no delimiter and column positions specified as input

      1.2hello there3
      2.4many words 7

  This class is just a convenience wrapper around the `FixedWidth` reader but with `header.start_line = None` and `data.start_line = 0`.

  See the Fixed-width Gallery for specific usage examples.

  Parameters:

  - col_starts – list of start positions for each column (0-based counting)
  - col_ends – list of end positions (inclusive) for each column
  - delimiter_pad – padding around delimiter when writing (default = None)
  - bookend – put the delimiter at start and end of line when writing (default = False)