MCPcopy Create free account
hub / github.com/cogentcore/core / ColumnIndex

Method ColumnIndex

tensor/table/table.go:88–94  ·  view source on GitHub ↗

ColumnIndex returns the index of the given column name. returns -1 if name not found -- see Try version for error message.

(name string)

Source from the content-addressed store, hash-verified

86// ColumnIndex returns the index of the given column name.
87// returns -1 if name not found -- see Try version for error message.
88func (dt *Table) ColumnIndex(name string) int {
89 i, ok := dt.ColumnNameMap[name]
90 if !ok {
91 return -1
92 }
93 return i
94}
95
96// ColumnIndexTry returns the index of the given column name,
97// along with an error if not found.

Callers 15

ColumnIndexesByNamesMethod · 0.95
RowsByStringMethod · 0.95
SetTensorMethod · 0.95
genPlotXYMethod · 0.80
genPlotBarMethod · 0.80
AggByColumnNameMethod · 0.80
AppendRowsMethod · 0.80
RowsByStringMethod · 0.80
AggColumnFunction · 0.80
DescColumnFunction · 0.80
QuantilesFunction · 0.80
DescColumnFunction · 0.80

Implementers 1

_cogentcore_org_core_plot_plots_Tableyaegicore/symbols/cogentcore_org-core-

Calls

no outgoing calls

Tested by

no test coverage detected