DataFrame.pow
Get Exponential power of dataframe and other, element-wise (binary operator pow).
Parameters
Type
Description
Default
Examples
Exponential of scalar with DataFrame along default axis 1
const dfd = require("danfojs-node")
let data = {
"Col1": [10, 45, 56, 10],
"Col2": [23, 20, 10, 24]
}
let df = new dfd.DataFrame(data)
let df_new = df.pow(2)
df_new.print()╔════════════╤═══════════════════╤═══════════════════╗
║ │ Col1 │ Col2 ║
╟────────────┼───────────────────┼───────────────────╢
║ 0 │ 100 │ 529 ║
╟────────────┼───────────────────┼───────────────────╢
║ 1 │ 2025 │ 400 ║
╟────────────┼───────────────────┼───────────────────╢
║ 2 │ 3136 │ 100 ║
╟────────────┼───────────────────┼───────────────────╢
║ 3 │ 100 │ 576 ║
╚════════════╧═══════════════════╧═══════════════════╝
Exponential of Series with DataFrame along axis 0
Exponential of DataFrame with another DataFrame
Exponential of Array with DataFrame along axis 0
Exponential works inplace
Last updated