Skip to main content

A package for wrangling and tidy data in python.

Project description

wrangle_in_py

Documentation Status codecov

A package for wrangling and tidy data in python. This package includes functions to assist the user with common data wrangling and tidying tasks in python such as changing column names or removing duplicate rows.

User-Facing Functions

This package consists of the following user-facing functions:

  • column_name_standardizer: Returns a copy of the inputted dataframe with standardized column names.
  • extracting_ymd: Returns a copy of the inputted dataframe with three new columns: year, month, and day, splitting from inputted datetime column name.
  • extracting_hms: Returns a copy of the inputted dataframe with three new columns: hour, minute, and second, from inputted datetime column name.
  • remove_duplicates: Removes duplicate rows from a DataFrame based on specified columns.
  • column_drop_threshold: Returns a copy of the dataframe inputted with columns removed if they did not meet the threshold specified or if they had a lower coefficient of variance than specified.

Helper Functions

This package also includes the following helper functions:

  • string_standardizer: Returns a string that is converted to lowercase and its non-alphanumerics (including spaces and punctuation) are replaced with underscores. A helper function for column_name_standardizer.
  • resulting_duplicates: Identifies which strings became duplicates after standardization. A helper function for column_name_standardizer.

This package fills a niche in the Python ecosystem by offering specialized tools for tidying and wrangling data, focusing on standardizing column names and strings, detecting duplicates after standardization, and extracting components from datetime columns. While libraries like pandas provide general-purpose methods for similar tasks, such as renaming columns or working with datetime data, these often require multiple steps or custom scripts. By combining these focused functionalities into a single package, it offers a lightweight, user-friendly alternative for efficient data preprocessing.

Installation

$ pip install wrangle_in_py

Documentation

Our online documentation can be found here.

Contributing

Interested in contributing? Check out the contributing guidelines. Please note that this project is released with a Code of Conduct. By contributing to this project, you agree to abide by its terms.

License

wrangle_in_py was created by Shannon Pflueger, Stephanie Ta, Wai Ming Wong, Yixuan(Clara) Gao. It is licensed under the terms of the MIT license and Creative Commons Attribution 4.0 International License. LICENSE

Credits

wrangle_in_py was created with cookiecutter and the py-pkgs-cookiecutter template.

Contributors

  • Shannon Pflueger
  • Stephanie Ta
  • Wai Ming Wong
  • Yixuan(Clara) Gao

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wrangle_in_py-0.0.3.tar.gz (7.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wrangle_in_py-0.0.3-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file wrangle_in_py-0.0.3.tar.gz.

File metadata

  • Download URL: wrangle_in_py-0.0.3.tar.gz
  • Upload date:
  • Size: 7.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for wrangle_in_py-0.0.3.tar.gz
Algorithm Hash digest
SHA256 7148680f92e6cd3617f4afd9a4c44a40f02dbcb4893a55f96c8a6e9c4093cd93
MD5 90147f1862cbd368659c677237337daa
BLAKE2b-256 7691d6b8180d36295bc03032d8b7dc0b393e933e3cc08c5dfb0eeae52e6e5869

See more details on using hashes here.

File details

Details for the file wrangle_in_py-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: wrangle_in_py-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 9.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for wrangle_in_py-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 6d41207b32bcae92dfbcb0fbb9162778b5990333a2d515d3c3dba7f1428d9e30
MD5 b1e704dd3e99763448817d557b5f037d
BLAKE2b-256 d882024c8cad2894c65e193089949dca5553fa08f12aff35433c32843be00f26

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page