Odin has a dedicated attribute overview with examples

TableMatrixAttribute class

Namespace: Sirenix.OdinInspector
Assembly: Sirenix.OdinInspector.Attributes
[AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Module | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum | AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Interface | AttributeTargets.Parameter | AttributeTargets.Delegate | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter | AttributeTargets.All, AllowMultiple = false)]
public class TableMatrixAttribute : Attribute, _Attribute
The TableMatrix attribute is used to further specify how Odin should draw two-dimensional arrays.
  • System.Object
  • System.Attribute
  • TableMatrixAttribute
// Inheriting from SerializedMonoBehaviour is only needed if you want Odin to serialize the multi-dimensional arrays for you.
// If you prefer doing that yourself, you can still make Odin show them in the inspector using the ShowInInspector attribute.
public class TableMatrixExamples : SerializedMonoBehaviour
    [InfoBox("Right-click and drag column and row labels in order to modify the tables."), PropertyOrder(-10), OnInspectorGUI]
    private void ShowMessageAtOP() { }

    [BoxGroup("Two Dimensional array without the TableMatrix attribute.")]
    public bool[,] BooleanTable = new bool[15, 6];

    [BoxGroup("ReadOnly table")]
    [TableMatrix(IsReadOnly = true)]
    public int[,] ReadOnlyTable = new int[5, 5];

    [BoxGroup("Labled table")]
    [TableMatrix(HorizontalTitle = "X axis", VerticalTitle = "Y axis")]
    public GameObject[,] LabledTable = new GameObject[15, 10];

    [BoxGroup("Enum table")]
    [TableMatrix(HorizontalTitle = "X axis")]
    public InfoMessageType[,] EnumTable = new InfoMessageType[4,4];

    [BoxGroup("Custom table")]
    [TableMatrix(DrawElementMethod = "DrawColoredEnumElement", ResizableColumns = false)]
    public bool[,] CustomCellDrawing = new bool[30,30];


        private static bool DrawColoredEnumElement(Rect rect, bool value)
            if (Event.current.type == EventType.MouseDown && rect.Contains(Event.current.mousePosition))
                value = !value;
                GUI.changed = true;

            UnityEditor.EditorGUI.DrawRect(rect.Padding(1), value ? new Color(0.1f, 0.8f, 0.2f) : new Color(0, 0, 0, 0.5f));

            return value;



public TableMatrixAttribute()


Override how Odin draws each cell.


public MyType[,] myArray;

private static MyType DrawElement(Rect rect, MyType value) { return GUI.DrawMyType(rect, value); }

public string DrawElementMethod
If true, no column indices drawn.
public bool HideColumnIndices
If true, no row indices drawn.
public bool HideRowIndices
The horizontal title label.
public string HorizontalTitle
If true, inserting, removing and dragging columns and rows will become unavailable. But the cells themselves will remain modifiable. If you want to disable everything, you can use the attribute.
public bool IsReadOnly
Whether or not columns are resizable.
public bool ResizableColumns
Whether the drawn table should respect the current GUI indent level.
public bool RespectIndentLevel
The height for all rows. 0 = default row height.
public int RowHeight
If true, the height of each row will be the same as the width of the first cell.
public bool SquareCells
If true, tables are drawn with rows/columns reversed (C# initialization order).
public bool Transpose
The vertical title label.
public string VerticalTitle

This website is brand new and built with the Odin 2.1 beta in mind. This means you might discover some features such as attribute expressions that are only available in the beta.

You can download the 2.1 beta from here and read the patch-notes here.