8.13.25 TableModel class: A table model that represent data as a two-dimensional array of items.

data is any tabular data organized in a fixed number of rows and colums. This means that an item at row i and column j can be addressed as data[i][j]. Optional lists of column and row headers can be specified.

The TableModel class has this constructor:

class TableModel( data,chead=None,rhead=None,parent=None)

TableModel objects have the following methods:

rowCount( parent=None)

columnCount( parent=None)

data( index,role)

headerData( col,orientation,role)

insertRows( row=None,count=None)

removeRows( row=None,count=None)