Polars Expression Transformer
=============================
Polars Expression Transformer is a Python library that provides a simple and intuitive way to transform and manipulate data using Polars expressions. It is designed for users who are familiar with SQL and Tableau and want to leverage the power of Polars for data processing tasks.
Purpose
-------
The purpose of Polars Expression Transformer is to provide a high-level interface for working with Polars expressions. It allows users to write simple string expressions that can be easily translated into Polars expressions, making it easy to perform complex data transformations without having to write Python code.
Target Group
------------
Polars Expression Transformer is ideal for users who:
* Are familiar with SQL or Tableau and want to use Polars for data transformation tasks.
* Want to perform complex data transformations without having to write Python code.
* Need to integrate Polars into an application or tool and want to provide a simple and intuitive interface for users to perform data transformations.
When to Use
-----------
Polars Expression Transformer is particularly useful in the following scenarios:
* When you are not directly exposed to Python, for example in an application.
* When you want to provide a simple and intuitive interface for users to perform complex data transformations without having to write Python code.
When Not to Use
--------------
Polars Expression Transformer may not be the best choice for users who:
* Are already familiar with Polars and are developing in an IDE. In this case, it may be more efficient to write Polars expressions directly.
* Want to have the best performance and all features of Polars. Polars Expression Transformer adds an additional layer on top of Polars, which may result in a performance overhead.
* Need to perform low-level optimizations or custom transformations that are not supported by Polars Expression Transformer
Installation
------------
To install Polars Expression Transformer, you can use pip:
```
pip install polars-expr-transformer
```
Example Use Case
----------------
Let's say you have a Polars DataFrame `df` with columns "names" and "subnames", and you want to create a new column "combined" that concatenates the values in "names" and "subnames" with a space in between.
Without Polars Expression Transformer, you would need to write Python code to accomplish this:
```python
df = df.with_column(pl.col("names") + " " + pl.col("subnames").alias("combined"))
```
With Polars Expression Transformer, you can write a simple string expression instead:
```python
from polars_expr_transformer.process.polars_expr_transformer import simple_function_to_expr
df = df.select(simple_function_to_expr('concat([names], " ", [subnames])').alias("combined"))
```
This makes it easy to perform complex data transformations without having to write Python code.
Built on Polars
--------------
Polars Expression Transformer is built on top of the amazing Polars library. Polars is a blazing fast DataFrame library implemented in Rust and Python. It is designed to be a high-performance alternative to Pandas and other DataFrame libraries. I highly recommend checking out Polars if you are working with large datasets or need to perform complex data transformations quickly.
Acknowledgements
----------------
We would like to thank the Polars team for creating such an amazing library.
Raw data
{
"_id": null,
"home_page": "https://github.com/edwardvaneechoud/polars_expr_transformer",
"name": "polars-expr-transformer",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": null,
"author": "Edward van Eehoud",
"author_email": "evaneechoudl@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/40/c0/366ab37212554008fdae0de0dbeb256abc176cf55a66d5d448a8052091aa/polars_expr_transformer-0.1.3.6.tar.gz",
"platform": null,
"description": "Polars Expression Transformer\n=============================\n\nPolars Expression Transformer is a Python library that provides a simple and intuitive way to transform and manipulate data using Polars expressions. It is designed for users who are familiar with SQL and Tableau and want to leverage the power of Polars for data processing tasks.\n\nPurpose\n-------\n\nThe purpose of Polars Expression Transformer is to provide a high-level interface for working with Polars expressions. It allows users to write simple string expressions that can be easily translated into Polars expressions, making it easy to perform complex data transformations without having to write Python code.\n\nTarget Group\n------------\n\nPolars Expression Transformer is ideal for users who:\n\n* Are familiar with SQL or Tableau and want to use Polars for data transformation tasks.\n* Want to perform complex data transformations without having to write Python code.\n* Need to integrate Polars into an application or tool and want to provide a simple and intuitive interface for users to perform data transformations.\n\nWhen to Use\n-----------\n\nPolars Expression Transformer is particularly useful in the following scenarios:\n\n* When you are not directly exposed to Python, for example in an application.\n* When you want to provide a simple and intuitive interface for users to perform complex data transformations without having to write Python code.\n\nWhen Not to Use\n--------------\n\nPolars Expression Transformer may not be the best choice for users who:\n\n* Are already familiar with Polars and are developing in an IDE. In this case, it may be more efficient to write Polars expressions directly.\n* Want to have the best performance and all features of Polars. Polars Expression Transformer adds an additional layer on top of Polars, which may result in a performance overhead.\n* Need to perform low-level optimizations or custom transformations that are not supported by Polars Expression Transformer\n\nInstallation\n------------\n\nTo install Polars Expression Transformer, you can use pip:\n```\npip install polars-expr-transformer\n```\nExample Use Case\n----------------\n\nLet's say you have a Polars DataFrame `df` with columns \"names\" and \"subnames\", and you want to create a new column \"combined\" that concatenates the values in \"names\" and \"subnames\" with a space in between.\n\nWithout Polars Expression Transformer, you would need to write Python code to accomplish this:\n```python\ndf = df.with_column(pl.col(\"names\") + \" \" + pl.col(\"subnames\").alias(\"combined\"))\n```\nWith Polars Expression Transformer, you can write a simple string expression instead:\n```python\nfrom polars_expr_transformer.process.polars_expr_transformer import simple_function_to_expr\n\ndf = df.select(simple_function_to_expr('concat([names], \" \", [subnames])').alias(\"combined\"))\n```\nThis makes it easy to perform complex data transformations without having to write Python code.\n\nBuilt on Polars\n--------------\n\nPolars Expression Transformer is built on top of the amazing Polars library. Polars is a blazing fast DataFrame library implemented in Rust and Python. It is designed to be a high-performance alternative to Pandas and other DataFrame libraries. I highly recommend checking out Polars if you are working with large datasets or need to perform complex data transformations quickly.\n\nAcknowledgements\n----------------\n\nWe would like to thank the Polars team for creating such an amazing library.\n",
"bugtrack_url": null,
"license": null,
"summary": "Transform string-based expressions into Polars DataFrame operations",
"version": "0.1.3.6",
"project_urls": {
"Homepage": "https://github.com/edwardvaneechoud/polars_expr_transformer"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "dafa2c82ce3f999741661eb951394cf8119e175c6f62a528c8da0e69ba14d53c",
"md5": "22d7478894ed2adbf6104ab09c2d7907",
"sha256": "4308f6301d0fcd36700bfc75bacdd4da37856a4c5305cbc05dc444506581dc59"
},
"downloads": -1,
"filename": "polars_expr_transformer-0.1.3.6-py3-none-any.whl",
"has_sig": false,
"md5_digest": "22d7478894ed2adbf6104ab09c2d7907",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 29158,
"upload_time": "2024-05-15T16:35:54",
"upload_time_iso_8601": "2024-05-15T16:35:54.339950Z",
"url": "https://files.pythonhosted.org/packages/da/fa/2c82ce3f999741661eb951394cf8119e175c6f62a528c8da0e69ba14d53c/polars_expr_transformer-0.1.3.6-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "40c0366ab37212554008fdae0de0dbeb256abc176cf55a66d5d448a8052091aa",
"md5": "71d3b49f218160cb56fa0298b098d32c",
"sha256": "7021cc91cff9bde9f8cba48f0dfca0638bc8b0f23dbfa84ac99aa7d8f05c30b0"
},
"downloads": -1,
"filename": "polars_expr_transformer-0.1.3.6.tar.gz",
"has_sig": false,
"md5_digest": "71d3b49f218160cb56fa0298b098d32c",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 25957,
"upload_time": "2024-05-15T16:35:59",
"upload_time_iso_8601": "2024-05-15T16:35:59.659463Z",
"url": "https://files.pythonhosted.org/packages/40/c0/366ab37212554008fdae0de0dbeb256abc176cf55a66d5d448a8052091aa/polars_expr_transformer-0.1.3.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-15 16:35:59",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "edwardvaneechoud",
"github_project": "polars_expr_transformer",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "polars-expr-transformer"
}