-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4574ee6
commit 19f16f2
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# API Reference | ||
|
||
Anything documented in the API reference is intended to work consistently among | ||
supported backends. | ||
|
||
For example: | ||
```python | ||
import narwhals as nw | ||
|
||
nw: DataFrame | ||
nw.with_columns( | ||
a_mean = nw.col('a').mean(), | ||
a_std = nw.col('a').std(), | ||
) | ||
``` | ||
is supported, as `DataFrame.with_columns`, `narwhals.col`, `Expr.mean`, and `Expr.std` are | ||
all documented in the API reference. | ||
|
||
However, | ||
```python | ||
import narwhals as nw | ||
|
||
nw: DataFrame | ||
nw.with_columns( | ||
a_ewm_mean = nw.col('a').ewm_mean(alpha=.7), | ||
) | ||
``` | ||
is not - `Expr.ewm_mean` only appears in the Polars API reference, but not in the Narwhals | ||
one. | ||
|
||
In general, you should expect any fundamental dataframe operation to be supported - if | ||
one that you need is not, please do open a feature request! |