Tabla de datos
La página “ElementsDataTable” no existe en Castellano todavía.
Puede ver la página correspondiente en Inglés (si existe) aquí debajo
(Available in the
palette of the Interface group.)
A Data Table collects data row by row using the table’s Input property. Every time the input row changes, the table adds another row. The table grows as the model evolves.

Click on the image to start the applet.
EJS Data Table example: a DataTable is used to display the values of the sine function. Download this example and unzip it in your source code directory.
Properties
Property values in the Data Table inspector.
DataTable  |
Main |
Name | Description | Values accepted | Default |
Input | The data to display. | A constant or variable of type double, double[] or int. | |
Max Points | The maximum number of input data to display. | A constant or variable of type int. Select −1 to display all the data. | |
Active | Whether the element actually accepts input data. | A boolean variable or one of the constants true or false. | |
No Repeat | Whether to ignore equal succesive points. | A boolean variable or one of the constants true or false. | |
Stride | The stride when displaying the data. | A constant or variable of type int. | |
Show Row Number | Whether to display the row numbers. | A boolean variable or one of the constants true or false. | |
Column Names | The number for the columns. | A String or String[] variable. Example new String[]{”#”,”t”,”x”} | |
Column Format | The format of the columns, i.e. the number of decimal digits with which to display the value. | Type 0.0 with one or more zeros after the point. Example new String[]{”0.0”,”0.0”,”0.0”} | |
Graphical Aspect |
Name | Description | Values accepted | Default |
Size | The double[] array with the size of the frame in each direction. | Type the two size values or use the editor provided. | |
Background | The background color for the element. | Use the editor provided or read about colors. | |
Foreground | The color to use when drawing or writing in the element. | Use the editor provided or read about colors. | |
Font | The font used to display text in the element. | Use the editor provided to select name, style and size of the font. | |
Tooltip | Text displayed when the mouse is over the element. | A string constant or variable. | |
Methods
Public methods of the DataTable element that can be invoked in a code page.
Signature | Description |
void appendRow(double[] x) | Appends a row of data with the given values to the table. |
void appendRow(int[] x) | Appends a row of data with the given values to the table. |
void appendRow(byte[] x) | Appends a row of data with the given values to the table. |
void appendRow(Object[] x) | Appends a row of data with the given values to the table. |
void clearData() | Clears data from this table. Column names and format patterns are not affected. |
Further examples
(deliberately left empty)