Skip to main content

Disclaimer: This is an old Project from when I started learning Python from 2019 (not the best written code)!! A GUI for flexibly organizing Data Analytics related tasks/functions and adding custom User Input Fields if needed.

Project description

MIT License


Tiny Data Analytics Tool

A tiny data analytics tool from when I started learning Python

Table of Contents
  1. About The Project
  2. Getting Started
  3. License

About The Project

This is a tiny Data Analytics Tool from when started learning Python in 2019. I don't maintain it and decided primarily to publish it for a friend of mine, who needed such “tiny” tool for his local Data Analytics Scripts. An Example of how to use is provided below under the Getting Started section.

That said... This is a tiny tool encompassing a GUI for flexibly organizing Data Analytics related tasks/functions and adding custom User Input Fields if needed. It builds up a Tkinter GUI where custom functions can be started and if needed provide User Input. It can plainly execute some logic or render Matplotlib Graphs.

(back to top)

Built With

Python

(back to top)

Getting Started

import pandas as pd
from tiny_data_analytics_tool.TinyDataAnalyticsTool import TinyDataAnalyticsTool
import matplotlib.pyplot as plt
import matplotlib
matplotlib.use("TkAgg")

def myFunc(*args, **kwargs):
    # Nested dictionary of User Input including Tkinter Objects for further manipulations if required
    user_inputs : dict = kwargs.get('user_inputs') 
    # Trimmed only if User did NOT select option 'All' 
    trimmed_data_based_on_user_input :pd.DataFrame = kwargs.get('data') 
    print(user_inputs)
    print(trimmed_data_based_on_user_input)
    plt.hist(trimmed_data_based_on_user_input["Column1"])
    plt.show()

def main():                      
    #Import: Use the function name (e.g. myFunc) consistent 

    # Read your Data as Pandas Data Frame
    data = pd.DataFrame({'Column1': [1,2,3,4,5],'Column2':[5,4,3,2,1]})

    #Here you give as parameter your Data
    dict_data = {'myFunc' : data}

    #Here you specify the function which shall be called in the Analytics Class above
    func_dict = {"myFunc" : myFunc}

    #Here you specify special options for your DropDown menu, for example if the analysis should be based on relative or absoloute values
    #You can pass multiple special dicts in form of a nested dict
    dict_special_dropdown_options = {'myFunc' : {'Method (Parameters to choose from as a User not in dataset)' : ['Mean' , 'Median', 'Standarddeviation']}}

    #Here you specify Parameters which correspond to the column names in the dataFrame
    option_parameters_from_dataset_columns = {"myFunc" : ['Column1', 'Column2']}

    #here you can change the name of the column names for aesthetic reasons.
    func_parameters_desc = {"myFunc" : {'Column1' : 'Choice 1', 'Column2' : 'Choice 2'}}
    
    #Create the Gui and insert the parameters
    TinyDataAnalyticsTool(func_dict, option_parameters_from_dataset_columns, dict_data = dict_data,
            func_parameters_display_descr=func_parameters_desc,
            dict_special_dropdown_options=dict_special_dropdown_options)

if __name__ == '__main__':
    main()

Prerequisites

Python >=3.6

Installation

pip install TinyDataAnalyticsTool

(back to top)

License

Distributed under the MIT License. See LICENSE for more information.

(back to top)

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

TinyDataAnalyticsTool-0.1.0.tar.gz (7.6 kB view hashes)

Uploaded Source

Built Distribution

TinyDataAnalyticsTool-0.1.0-py3-none-any.whl (9.2 kB view hashes)

Uploaded Python 3

Supported by

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