new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Apache ECharts · all subjects

matrix

19 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

matrix label option properties

The label object option for matrix cells is available in version 6.0.0 and later. It supports formatter, defaultColor set to '#333', and standard label properties.

matrix itemStyle option properties

The itemStyle object option for matrix cells is available in version 6.0.0 and later. It supports defaultColor set to 'none', defaultBorderColor set to '#ccc', and defaultBorderWidth set to 1. It includes standard item style properties.

matrix cell cursor option

The cursor option is a string property that specifies the mouse cursor style when hovering over a matrix cell.

matrix cell z2 option

The z2 option is a number property that specifies the z-index or z-order of a matrix cell. It is used to resolve style conflicts, particularly when dealing with thick border styles.

matrix levelSize option definition and location

The levelSize option is available in version 6.0.0 and later. It specifies the size of all cells in a row or a column. For matrix.x, it refers to cell height of a row. For matrix.y, it refers to cell width of a column. It can be declared at matrix.levelSize to specify the default size for every column or row, or at matrix.levels[i].levelSize to specify the size of a certain column or row.

matrix size option definition and location

The size option specifies the size of a single cell. For matrix.x, it refers to cell width. For matrix.y, it refers to cell height. It is declared in matrix.x/y.data[i].size.

matrix levelSize and size value types and defaults

levelSize and size values can be: unspecified (default) where width or height is evenly distributed; a number representing pixel value; or a string representing percentage value (e.g., '33%'), where the percentage is relative to the width of the matrix for matrix.x or the height of the matrix for matrix.y.

matrix cell sizing example

Example showing how to configure matrix cell sizes: for matrix.x with levels having the second row at 10% of matrix width and other rows evenly distributed, with the first cell width at 30 pixels and other cell widths evenly distributed. Similarly for matrix.y with the second column at 10% of matrix width and first cell height at 30 pixels.

matrix dataToPoint and dataToLayout API coord rule

The dataToPoint and dataToLayout APIs use the same locating rule as matrix.data.coord. For example, input ['Xa1', 'Yb1'] to dataToPoint returns a point at the center of the corresponding body cell, and input to dataToLayout returns the bounding rectangle of that cell.

matrix.body.data.value and matrix.corner.data.value option

The value option is a string or number that specifies the text to display in the cell. It is optional.

matrix.body.mergeCells and matrix.corner.mergeCells option

mergeCells is a boolean option (default false) that allows body cells or corner cells to be merged.

matrix.body.coordClamp and matrix.corner.coordClamp option

coordClamp is a boolean option (default false). When true, matrix.body/corner.data[i].coord can use [null/undefined/NaN/invalid_values, xxx] or [xxx, null/undefined/NaN/invalid_values] to refer to entire rows or columns. When false, such values are disallowed and an error message is printed in dev mode.

matrix.body.data and matrix.corner.data introduced in version 6.0.0

The data option for matrix body and corner cells was introduced in Apache ECharts version 6.0.0.

matrix.body.data and matrix.corner.data structure

The data option for matrix body and corner cells accepts an array of cell objects. Each cell object has the following structure: coord (required array to locate the cell), value (optional string or number for text to display), and mergeCells (optional boolean, false by default).

matrix.body.data and matrix.corner.data.coord locating rule

Cell coordinates use a locator system with the top-left body cell as origin (0, 0). Non-negative locators indicate right/bottom direction, negative locators indicate left/top direction. Cells can be located by: locator numbers (integers), ordinal numbers (non-negative integers matching leaf dimension positions), or original value strings from matrix.x/y.data. Format examples: [2, 8] for a single cell, [[2, 5], 8] for a horizontal range, [[2, 5], [7, 8]] for a rectangular range, ['aNonLeaf', 8] for non-leaf dimension range. When coordClamp is true, [null/undefined/NaN, xxx] refers to an entire column and [xxx, null/undefined/NaN] refers to an entire row.

matrix.body.data.coord ordinal number assignment

Ordinal numbers are non-negative integers assigned to each leaf dimension cell value. In a hierarchy like matrix.x: [{ value: 'Xa0', children: ['Xb0', 'Xb1'] }, 'Xa1'] and matrix.y: [{ value: 'Ya0', children: ['Yb0', 'Yb1'] }], ordinal numbers are assigned as: 'Xb0'=0, 'Xb1'=1, 'Xa1'=2, 'Ya0'=0, 'Yb0'=0, 'Yb1'=1 (within their respective x/y hierarchies). For leaf dimension cells, ordinal number and matrix locator are identical.

matrix.body.data.coord multiple locating examples

A body cell can be located in multiple ways: [1, 0] uses locator numbers, ['Xb1', 'Yb0'] uses value strings, ['Xb1', 0] mixes both. A corner cell can use negative locators like [-2, -1]. Cross cells (multiple cells) can be located with ranges like [['Xb0', 'Xb1'], ['Yb0', 'Yb1']] or by non-leaf dimensions like ['Xa0', 'Yb0'].

matrix.body.data.coord format specification

The coord format follows these patterns: [2, 8] is a single cell, [[2, 5], 8] is a horizontal range in x from 2 to 5 at y position 8, [[2, 5], [7, 8]] is a rectangular range with x from 2 to 5 and y from 7 to 8, ['aNonLeaf', 8] locates a rectangular range using a non-leaf dimension name, [2, null/undefined/NaN] refers to an entire column at x position 2 (requires coordClamp: true), [null/undefined/NaN, 8] refers to an entire row at y position 8 (requires coordClamp: true), [[2, 5], null/undefined/NaN] refers to x range 2-5 for entire column (requires coordClamp: true).

matrix.body bodyR origin position

The body cell bodyR (top-left body cell) is located at coordinate [0, 0].

Give your agent this brain