← ln operator page · numeric/ln/ds/manual_ex_1
pandas ✅ · DuckDB ✅
ln on every measure of DS_1.
Natural logarithm, Example 1, output verbatim: "The operator ln calculates the natural logarithm of a number."
Me_1 148.413, 2980.95 and 7.38905 give 5.0, 8.0 and 2.0; Me_2 0.7545, 13.45 and 1.87 give -0.2817, 2.598979 and 0.625938, as the page prints them, shortened.
DS_r := ln(DS_1);
| Id_1 | Id_2 | Me_1 | Me_2 |
|---|---|---|---|
| 10 | A | 148.413 | 0.7545 |
| 10 | B | 2980.95 | 13.45 |
| 11 | A | 7.38905 | 1.87 |
{
"datasets": [
{
"name": "DS_1",
"DataStructure": [
{"name": "Id_1", "type": "Integer", "role": "Identifier", "nullable": false},
{"name": "Id_2", "type": "String", "role": "Identifier", "nullable": false},
{"name": "Me_1", "type": "Number", "role": "Measure", "nullable": true},
{"name": "Me_2", "type": "Number", "role": "Measure", "nullable": true}
]
}
]
}
| Id_1 | Id_2 | Me_1 | Me_2 |
|---|---|---|---|
| 10 | A | 5.0 | -0.2817 |
| 10 | B | 8.0 | 2.598979 |
| 11 | A | 2.0 | 0.625938 |
{
"datasets": [
{
"name": "DS_r",
"DataStructure": [
{"name": "Id_1", "type": "Integer", "role": "Identifier"},
{"name": "Id_2", "type": "String", "role": "Identifier"},
{"name": "Me_1", "type": "Number", "role": "Measure"},
{"name": "Me_2", "type": "Number", "role": "Measure"}
]
}
]
}