formatRowWhere
The formatRowWhere method applies color formatting to rows of the source table, based on user-specified conditions.
Syntax
table.formatRowWhere(condition, formula)
Parameters
| Parameter | Type | Description |
|---|---|---|
| condition | String | The condition expression. |
| formula | String | Formulas to compute formats for columns or rows in the table; e.g., For decimal formats, the result must be a string, and the formula must be wrapped in the special internal function |
Returns
A new table applies the specified formatting to the source table.
Examples
In the following example, we use formatRowWhere to paint rows where X is greater than 2 red.
tt = timeTable("PT1S").update("X = ii")
result = tt.formatRowWhere("X > 2", "RED").view()