添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

Dataframe 0.12 Help

update

Returns DataFrame with changed values in some cells. Column types can not be changed.

update { columns } [.where { rowCondition } ] [.at(rowIndices) ] .with { rowExpression } | .notNull { rowExpression } | .perCol { colExpression } | .perRowCol { rowColExpression } | .withNull() | .withZero() | .asFrame { frameExpression } rowCondition: DataRow.(OldValue) -> Boolean rowExpression: DataRow.(OldValue) -> NewValue colExpression: DataColumn.(DataColumn) -> NewValue rowColExpression: (DataRow, DataColumn) -> NewValue frameExpression: DataFrame.(DataFrame) -> DataFrame

See column selectors and row expressions

df.update { age }.with { it * 2 } df.update { colsOf<String>().recursively() }.with { it.uppercase() } df.update { weight }.at(1..4).notNull { it / 2 } df.update { name.lastName and age }.at(1, 3, 4).withNull()