utipy


Nameutipy JSON
Version 1.0.2 PyPI version JSON
download
home_pagehttps://github.com/ludvigolsen/utipy
SummaryUtility functions for python
upload_time2024-04-25 19:46:44
maintainerNone
docs_urlNone
authorLudvig Renbo Olsen
requires_python<4.0,>=3.7
licenseMIT
keywords pandas numpy array ndarray groups folds kfold partitioning utilities logging time tools rolling windows time
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            utipy
--------

Utility functions for python.

Alpha stage. Subject to change. 

> https://pypi.python.org/pypi/utipy/     


Install from PyPI:

```shell
pip install utipy
```

Install from GitHub:

```shell
python -m pip install git+https://github.com/ludvigolsen/utipy
```

Update this package but not dependencies:

```shell
python -m pip install --force-reinstall --no-deps git+https://github.com/ludvigolsen/utipy
```


### Pandas operations

| Function                | Description |
|:------------------------|:------------|
| `makes_up()`            | Is a Series made up of a specific value (more than / less than / equal to a threshold) ? |
| `drop()`                | Drop rows / columns of dataframe based on the percentile appearance of a specified value |
| `polynomializer()`      | Add polynomials to numeric columns, i.e. v1, v1^2, v1^3, ... |
| `resemble()`            | Generate a Series resembling another Series |
| `move_column_inplace()` | Move a column to a specified index |

### Data grouping

| Function      | Description |
|:--------------|:------------|
| `group()`     | Create grouping factors with different methods |
| `partition()` | Create balanced partitions for train/test      |
| `fold()`      | Create balanced folds for cross-validation     |

### Array operations

| Function             | Description |
|:---------------------|:------------|
| `blend()`            | Blend two arrays of same length  |
| `windowed_reverse()` | Reverse array within windows     |
| `window()`           | Split array into rolling windows |
| `nan_stats()`, `print_nan_stats()` | Get NaN statistics |

### Time operations

| Class        | Description |
|:-------------|:------------|
| `StepTimer`  | Time a step of code in a `with` context |
| `Timestamps` | Record and keep track of timepoints     |

### Path operations

| Class/Function   | Description |
|:-----------------|:------------|
| `IOPaths`        | Keep track of in-/out paths with checks, directory creation, and a print summary |
| `mk_dir()`       | Create directory if it doesn't exist, with messaging of the created path         |
| `rm_dir()`       | Remove directory if it exists, with messaging of the deleted path                | 

### String operations

| Function      | Description |
|:--------------|:------------|
| `letter_strings()` | Generate n letter strings (aa, ab, ac, ...) |

### Other utilities

| Class/Function      | Description |
|:--------------------|:------------|
| `Messenger`         | Simplify messaging (print/log) with verbosity and indentation  |

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/ludvigolsen/utipy",
    "name": "utipy",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.7",
    "maintainer_email": null,
    "keywords": "pandas, numpy, array, ndarray, groups, folds, kfold, partitioning, utilities, logging, time, tools, rolling, windows, time",
    "author": "Ludvig Renbo Olsen",
    "author_email": "mail@ludvigolsen.dk",
    "download_url": "https://files.pythonhosted.org/packages/0f/8b/86b2818a4f881467e1c29212844efd07b3edf3f2dcede314dabb8aae8e86/utipy-1.0.2.tar.gz",
    "platform": null,
    "description": "utipy\n--------\n\nUtility functions for python.\n\nAlpha stage. Subject to change. \n\n> https://pypi.python.org/pypi/utipy/     \n\n\nInstall from PyPI:\n\n```shell\npip install utipy\n```\n\nInstall from GitHub:\n\n```shell\npython -m pip install git+https://github.com/ludvigolsen/utipy\n```\n\nUpdate this package but not dependencies:\n\n```shell\npython -m pip install --force-reinstall --no-deps git+https://github.com/ludvigolsen/utipy\n```\n\n\n### Pandas operations\n\n| Function                | Description |\n|:------------------------|:------------|\n| `makes_up()`            | Is a Series made up of a specific value (more than / less than / equal to a threshold) ? |\n| `drop()`                | Drop rows / columns of dataframe based on the percentile appearance of a specified value |\n| `polynomializer()`      | Add polynomials to numeric columns, i.e. v1, v1^2, v1^3, ... |\n| `resemble()`            | Generate a Series resembling another Series |\n| `move_column_inplace()` | Move a column to a specified index |\n\n### Data grouping\n\n| Function      | Description |\n|:--------------|:------------|\n| `group()`     | Create grouping factors with different methods |\n| `partition()` | Create balanced partitions for train/test      |\n| `fold()`      | Create balanced folds for cross-validation     |\n\n### Array operations\n\n| Function             | Description |\n|:---------------------|:------------|\n| `blend()`            | Blend two arrays of same length  |\n| `windowed_reverse()` | Reverse array within windows     |\n| `window()`           | Split array into rolling windows |\n| `nan_stats()`, `print_nan_stats()` | Get NaN statistics |\n\n### Time operations\n\n| Class        | Description |\n|:-------------|:------------|\n| `StepTimer`  | Time a step of code in a `with` context |\n| `Timestamps` | Record and keep track of timepoints     |\n\n### Path operations\n\n| Class/Function   | Description |\n|:-----------------|:------------|\n| `IOPaths`        | Keep track of in-/out paths with checks, directory creation, and a print summary |\n| `mk_dir()`       | Create directory if it doesn't exist, with messaging of the created path         |\n| `rm_dir()`       | Remove directory if it exists, with messaging of the deleted path                | \n\n### String operations\n\n| Function      | Description |\n|:--------------|:------------|\n| `letter_strings()` | Generate n letter strings (aa, ab, ac, ...) |\n\n### Other utilities\n\n| Class/Function      | Description |\n|:--------------------|:------------|\n| `Messenger`         | Simplify messaging (print/log) with verbosity and indentation  |\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Utility functions for python",
    "version": "1.0.2",
    "project_urls": {
        "Homepage": "https://github.com/ludvigolsen/utipy",
        "Repository": "https://github.com/ludvigolsen/utipy",
        "issues": "https://github.com/ludvigolsen/utipy/issues"
    },
    "split_keywords": [
        "pandas",
        " numpy",
        " array",
        " ndarray",
        " groups",
        " folds",
        " kfold",
        " partitioning",
        " utilities",
        " logging",
        " time",
        " tools",
        " rolling",
        " windows",
        " time"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "392603911abc90ffbad665864913d4bf249f5c704aedca2b7ce49abf45d39222",
                "md5": "bfedfc0175aab387b9d7f5da3a1d8c69",
                "sha256": "6848ac245f6bd60303e18064831df2a3a279573337e2b22a92ff7b0657fa87fe"
            },
            "downloads": -1,
            "filename": "utipy-1.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "bfedfc0175aab387b9d7f5da3a1d8c69",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.7",
            "size": 47919,
            "upload_time": "2024-04-25T19:46:42",
            "upload_time_iso_8601": "2024-04-25T19:46:42.401977Z",
            "url": "https://files.pythonhosted.org/packages/39/26/03911abc90ffbad665864913d4bf249f5c704aedca2b7ce49abf45d39222/utipy-1.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0f8b86b2818a4f881467e1c29212844efd07b3edf3f2dcede314dabb8aae8e86",
                "md5": "7becf41eca4bcf940a9c0cf4d1993258",
                "sha256": "665fcfb4cf98f5e203158b656ce0462d4a637dcf5c5ff2a76929bfc5cf2c4489"
            },
            "downloads": -1,
            "filename": "utipy-1.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "7becf41eca4bcf940a9c0cf4d1993258",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.7",
            "size": 35783,
            "upload_time": "2024-04-25T19:46:44",
            "upload_time_iso_8601": "2024-04-25T19:46:44.331278Z",
            "url": "https://files.pythonhosted.org/packages/0f/8b/86b2818a4f881467e1c29212844efd07b3edf3f2dcede314dabb8aae8e86/utipy-1.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-25 19:46:44",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "ludvigolsen",
    "github_project": "utipy",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "utipy"
}
        
Elapsed time: 0.39942s