Skip to main content

Define a Language Table

A table is a set of values indexed by name. You can define a table in the UI and on the language.

Units of columns

Here, each column is a list with the same length. As with lists, you can specify the units of a given column:

Columns with ranges

You can also declare a column like this:

Columns with calculations

Instead of manually inputting values, each column's cell can be based on the outputs of other cells:

Using columns as a whole

Sometimes, when deriving a column from another with an expression, you might want to use the whole column at once instead of doing your calculations on a row-by-row basis. Like when you want to know the maximum of a column:

Or analyze changes to your profits:

Using previous values

You can access previous column values by using the word previous and providing a value for the first cell, like this:

You can also access previous values from other columns by using the word previous, providing a value for the first cell and the name of the column you want to access. Here is an example notebook using previous to calculate the row-over-row change of a value. The basic syntax looks like this:

Access columns

You can access the table columns individually:

You can then use them as lists:

Even inside your table, you can refer to its previous columns, if you need to aggregate them.

Add columns

Add new columns to a defined table with . followed by their name. Their sizes must match the existing table columns.

Index column

You can use the first column as an index for the row by using cells of text:

When you extract a column, it remembers the original index:

You can still do operations on that column, and it will still remember the original index:

Defining a first value in a column

If you want to set an initial value in a column you can use the first keyword. This only works in table formulas.

Functions on tables

Here is a list of all the functions that work on tables.