DataFrame.cumMin
Return cumulative minimum over a DataFrame or Series axis.
Parameters
Type
Description
Default
Examples
Cumulative minimum of elements along axis 0 (row)
const dfd = require("danfojs-node")
let data = [[11, 20, 3], [1, 15, 6], [2, 30, 40], [2, 89, 78]]
let cols = ["A", "B", "C"]
let df = new dfd.DataFrame(data, { columns: cols })
let new_df = df.cumMin({ axis: 0 })
new_df.print()╔═══╤═══════════════════╤═══════════════════╤═══════════════════╗
║ │ A │ B │ C ║
╟───┼───────────────────┼───────────────────┼───────────────────╢
║ 0 │ 11 │ 20 │ 3 ║
╟───┼───────────────────┼───────────────────┼───────────────────╢
║ 1 │ 1 │ 15 │ 3 ║
╟───┼───────────────────┼───────────────────┼───────────────────╢
║ 2 │ 1 │ 15 │ 3 ║
╟───┼───────────────────┼───────────────────┼───────────────────╢
║ 3 │ 1 │ 15 │ 3 ║
╚═══╧═══════════════════╧═══════════════════╧═══════════════════╝Cumulative minimum of elements along column axis (1)
Last updated