DataFrame.insertColumn
Adds or replaces one column at a position. An existing name is replaced at its own position - the index applies to new names only. A new name is inserted at index, where 0 ..= width() is valid (width() appends, like withColumn).
Parameters
index | the insertion position for a new name |
col | the column to add or replace |
Returns
the new frame.
Throws
DataFrameException on a height mismatch or an index
beyond width() for a new name.