Skip to content

Commit

Permalink
Merge pull request #27 from MarcoGorelli/links
Browse files Browse the repository at this point in the history
Links
  • Loading branch information
MarcoGorelli authored Mar 24, 2024
2 parents 07cd722 + 105eab7 commit fbd142b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
src="https://github.com/MarcoGorelli/narwhals/assets/33491632/26be901e-5383-49f2-9fbd-5c97b7696f27">
</h1>

[![PyPI version](https://badge.fury.io/py/narwhals.svg)](https://badge.fury.io/py/narwhals)
[![Documentation](https://img.shields.io/badge/Documentation-coolgreen?style=flat&link=https://marcogorelli.github.io/narwhals/)](https://marcogorelli.github.io/narwhals/)

Extremely lightweight compatibility layer between Polars, pandas, modin, and cuDF (and possibly more?).

Seamlessly support all, without depending on any!
Expand All @@ -29,10 +32,9 @@ Or just vendor it, it's only a bunch of pure-Python files.

There are three steps to writing dataframe-agnostic code using Narwhals:

1. use `narwhals.LazyFrame` or `narwhals.DataFrame` to wrap a pandas or Polars
1. use `narwhals.DataFrame` or `narwhals.LazyFrame` to wrap a pandas/Polars/Modin/cuDF
DataFrame/LazyFrame in a Narwhals class
2. use the subset of the Polars API supported by Narwhals. Just like in Polars,
some methods (e.g. `to_numpy`) are only available for `DataFrame`, not `LazyFrame`
2. use the [subset of the Polars API supported by Narwhals](https://marcogorelli.github.io/narwhals/api-reference/narwhals/)
3. use `narwhals.to_native` to return an object to the user in its original
dataframe flavour. For example:

Expand Down

0 comments on commit fbd142b

Please sign in to comment.