Skip to main content

DataFilterTool is a Python package designed to

Project description

DataFilterTool

DataFilterTool is a Python package designed to facilitate filtering and analyzing employee data. It offers functionality to filter employees based on their date of joining and to calculate the average salary for a given designation. This package is suitable for use in various data analysis and human resources applications.

Features

  • Filter employees based on the date of joining.
  • Calculate the average salary for a given designation.
  • Organize input, output, and log files in separate directories.
  • Append timestamps to output and log files for tracking.
  • Utilize a configuration file to define the location of log files.

Installation

You can install DataFilterTool from PyPI using pip:

pip install DataFilterTool

Usage

Filtering Employees

To filter employees based on their date of joining, use the filter_by_date function. This function takes the date of joining as input and saves the filtered list of employees in a new file in the output directory.

from DataFilterTool.filter_by_date import filter_by_date

# Example usage
date_of_joining = "2022-01-01"
filter_by_date(date_of_joining)

Calculating Average Salary

To calculate the average salary for a given designation, use the average_salary_by_designation function. This function takes the designation as input and prints the average salary for that designation in an output file with a timestamp.

from DataFilterTool.avg_sal_by_des import average_salary_by_designation

# Example usage
designation = "Manager"
average_salary_by_designation(designation)

Configuration

You can customize the location of log files by modifying the configuration file (config.py). This allows you to specify the path to the log directory relative to the root user.

File Structure

dataFilterTool/
|-- init.py
|-- dataenv/
|-- DataFilterTool/
|   |-- __init__.py
|   |-- filter_by_date.py
|   |-- avg_sal_by_des.py
|   |-- config.py
|   |-- version.py
|-- .github/
|   |-- workflows/
|-- dataFilter_config/
|-- |-- init.py
|-- |-- config.ini
|-- input/
|   |-- employee_data.xlsx 
|-- output/
|   |-- average_salary_output.txt
|   |-- filtered_output_{timestamp}.xlsx
|-- logs/
|   |-- filtered_logs_{timestamp}.txt
|-- tests/
|   |-- test_filter_functions.py
|   |-- test_average_salary_functions.py
|-- scripts/
|   |-- data_generation.py
|-- setup.py
|-- MANIFEST.py
|-- README.md
|-- requirements.txt

Contributing

Contributions to DataFilterTool are welcome! If you have any suggestions, feature requests, or bug reports, please open an issue on the GitHub repository.

License

This project is licensed under the MIT License. See the LICENSE file for details.

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

dataFilterTool-0.0.9.tar.gz (17.7 kB view details)

Uploaded Source

Built Distribution

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

dataFilterTool-0.0.9-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file dataFilterTool-0.0.9.tar.gz.

File metadata

  • Download URL: dataFilterTool-0.0.9.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.5

File hashes

Hashes for dataFilterTool-0.0.9.tar.gz
Algorithm Hash digest
SHA256 e2d13a48baaa277e68ca7a079f7f852bb34de52651e391958c8b16607333d0ac
MD5 09f47f278c5e0ccdc0932b0bacb4cbb1
BLAKE2b-256 e53d26be7796997817e22ffb6fb21ce02292c555de3d5acb51fe21fa3ab2ba37

See more details on using hashes here.

File details

Details for the file dataFilterTool-0.0.9-py3-none-any.whl.

File metadata

  • Download URL: dataFilterTool-0.0.9-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.5

File hashes

Hashes for dataFilterTool-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 40ff9e16923391f924d6de0664acd3469bea90c6c41436ec14227bff1442baf4
MD5 6cbde44e0a8af17d0695279802a856af
BLAKE2b-256 494f9c16023cacfd7cf8548542f1aa4daca34b20766d3d19ca8f18d7c324c8c7

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