astrocook.core.column_names module#

The names of the columns of a spectrum (phase 6-quater, PR 8, F120).

One set of names for the user and the agents: those of the GUI, λ, λmin, λmax, F, dF for the columns that every spectrum has, and the other columns by their own name (cont, model, resol, …). The data keep their own names, x, xmin, xmax, y, dy (the archives, the CSV files of export_ascii, the attributes Spectrum.x, .y, .dy): accepted wherever a column is named, as silent and permanent aliases, as lam, lammin and lammax, the ASCII spelling of λ (Guido, 12 November 2026: shorter than lambda, which is a keyword of Python, e.g. df.lambda in pandas). So the logs, the saved expressions and the scripts written with either set still work, and nothing is translated in them.

The names of the parameters that name an axis and not a column keep x and y (xunit, xstart, dx, x_min of the tools, x_convert).

astrocook.core.column_names.GUI_COLUMN_NAMES: Dict[str, str] = {'F': 'y', 'dF': 'dy', 'λ': 'x', 'λmax': 'xmax', 'λmin': 'xmin'}#

name shown -> name of the data

Type:

The names of the columns of every spectrum

astrocook.core.column_names.ASCII_COLUMN_NAMES: Dict[str, str] = {'lam': 'x', 'lammax': 'xmax', 'lammin': 'xmin'}#

The ASCII spelling of the names of the axis

astrocook.core.column_names.CORE_COLUMNS = ('x', 'xmin', 'xmax', 'y', 'dy')#

The columns of every spectrum, by the names of the data

astrocook.core.column_names.AXIS_COLUMNS = ('x', 'xmin', 'xmax')#

The columns of the axis, by the names of the data

astrocook.core.column_names.internal_column(name: str) → str[source]#

The name in the data of the column called name (any spelling; a name of another column as it is).

astrocook.core.column_names.display_column(name: str) → str[source]#

The name shown of the column called name in the data.

astrocook.core.column_names.display_columns(names: Iterable[str]) → List[str][source]#

display_column() of each name.

astrocook.core.column_names.internal_expression(text: str) → str[source]#

text (an expression, or a comma-separated list of names) with the names of the columns of every spectrum written as in the data.

astrocook.core.column_names.is_core_column(name: str) → bool[source]#

Whether name (any spelling) is a column of every spectrum.

astrocook.core.column_names.is_axis_column(name: str) → bool[source]#

Whether name (any spelling) is a column of the axis (λ, λmin, λmax).