GithubHelp home page GithubHelp logo

banjtheman / fancylit Goto Github PK

View Code? Open in Web Editor NEW
9.0 9.0 4.0 49 KB

Fancylit is a python module that contains pre-packaged Streamlit code to render fancy visualizations, run modeling tasks, and data exploration

License: Apache License 2.0

Python 100.00%
machine-learning python streamlit visualization yellowbrick

fancylit's Introduction

Hello there ๐Ÿ‘‹

Im Banjo Obayomi a DataOps engineer based in the Washington DC area (DMV).

What is DataOps? DataOps is an automated, process-oriented methodology, used by analytic and data teams, to improve the quality and reduce the cycle time of data analytics.

Read more at https://www.dataopsmanifesto.org/

  • ๐Ÿ”ญ My Mantra ...

The end of learning is the begining of death

  • ๐Ÿ”ญ Iโ€™m currently working on ...

GitGallery - https://www.gitgallery.com/ - GitGallery allows you to mint your code into an NFT which can be sold on OpenSea
DataOps Podcast - https://anchor.fm/dataops -- A podcast about DataOps
DataOpsDC Meetup - https://www.meetup.com/DataOpsDC/ - Tech talks on DataOps
BlockchaindevDC - https://www.meetup.com/blockchaindevdc - Tech talks on Blockchain Development

  • ๐Ÿ“ซ How to reach me: ...

Twitter - https://twitter.com/banjtheman
Linkedin - https://www.linkedin.com/in/banjo-obayomi-a22520a4/
dev.to- https://dev.to/banjtheman

  • ๐Ÿ˜„ Pronouns: ... He/Him

fancylit's People

Contributors

banjtheman avatar direwolf707 avatar nat236919 avatar pedrogengo avatar rubyruins avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

fancylit's Issues

Brainstorm modules

What is the Task

Think of modules to create for fancylit

Why do we want to do this

To create great modules for fancylit

How can I get started?

Jot down any ideas in the comments

Definition of Done

N/A

Create Word Cloud from Column

What is the Task

Create a function that can render a wordcloud from a column in dataframe

Why do we want to do this

To provide an easy way to show a word cloud

How can I get started?

  1. Create a new function in data_stats.py called gen_wordcloud that takes in a data frame as a parameter/

  2. Have a drop-down select a column from the dataframe and create a wordcloud, here is example code
    https://github.com/amueller/word_cloud/blob/master/examples/simple.py

  3. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/stats/__init__.py

  4. Add the gen_wordcloud function to example_app.py

Definition of Done

Word cloud is rendered in example_app.py

Create Interactive HeatMap function

What is the Task

Create a function that can render an interactive heat map from a dataframe

Why do we want to do this

To provide an easy way to show a Heat Map

How can I get started?

  1. Create a new function in charts.py called heat_map that takes in a dataframe as a parameter

  2. Have the function provide selectable widgets for the graph axes like this https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L18-L23

  3. Render a Heat Map with Altair with the selected values, Example code:
    https://altair-viz.github.io/gallery/simple_heatmap.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/__init__.py

  5. Add the heat_map function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Heat map is rendered in example_app.py

Add a Class Prediction Function

What is the Task

Create a function that can render a Class Prediction Error Visualization from a dataframe and provide a way to make predictions

Why do we want to do this

To provide an easy way to show a Class Prediction Error Visualization and a method to make predictions

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called predict_class that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a Class Prediction Error Visualization:
    https://www.scikit-yb.org/en/latest/api/classifier/class_prediction_error.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the Class Prediction Errorfunction to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

  6. Render inputs that a user can enter values that correspond to each of the features for the model

  7. Have the model predict a class based on the user inputs, and display the result

Definition of Done

Class Prediction Error Visualization and class preidctior is rendered in example_app.py

Create Interactive Pair Plot function

What is the Task

Create a function that can render an interactive Pair Plot from a dataframe

Why do we want to do this

To provide an easy way to show a Pair Plot

How can I get started?

  1. Create a new function in charts.py called pair_plot that takes in a dataframe as a parameter

  2. Have the function provide selectable widgets for the graph axes like this https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L18-L23

  3. Render a Pair plot with Seaborn with the selected values, Example code:
    https://seaborn.pydata.org/generated/seaborn.pairplot.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/__init__.py

  5. Add the pair_plot function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Pair Plot is rendered in example_app.py

Integration with sklearn-evaluation

What is the Task

What do we want to accomplish?
Any plans on integrating with sklearn-evaluation for better visuals/plots?
It has more capabilities (bug fixes + new features) and is well-maintained.
Happy to assist!

Why do we want to do this

This will allow more capabilities and better user support.

How can I get started?

How can we start this task?

Definition of Done

How do we know this task is done?

Create Interactive Line Chart function

What is the Task

Create a function that can render an interactive line chart from a dataframe

Why do we want to do this

To provide an easy way to show a Line chart

How can I get started?

  1. Create a new function in charts.py called line_chart that takes in a dataframe as a parameter

  2. Have the function provide selectable widgets for the graph axes like this https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L18-L23

  3. Render a Line chart with Altair with the selected values, Example code:
    https://altair-viz.github.io/gallery/simple_line_chart.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/__init__.py

  5. Add the line_chart function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Line chart is rendered in example_app.py

Create a Feature Correlation Graph Function

What is the Task

Create a function that can render a Feature Correlation graph from a dataframe

Why do we want to do this

To provide an easy way to show a Feature Correlation graph

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called feature_correlation that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a Feature Correlation graph example code:
    https://www.scikit-yb.org/en/latest/api/target/feature_correlation.html?highlight=FeatureCorrelation#mutual-information-regression

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the Feature Correlation plot to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Feature Correlation is rendered in example_app.py

Create a Class Balance Function

What is the Task

Create a function that can render a Class Balance graph from a dataframe

Why do we want to do this

To provide an easy way to show a Class Balance graph

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called class_balance that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a Class Balance graph example code:
    https://www.scikit-yb.org/en/latest/api/target/class_balance.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the Class Balance function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Class Balance is rendered in example_app.py

Create a Prediction Error Plot

What is the Task

Create a function that can render a Prediction Error Plot from a dataframe

Why do we want to do this

To provide an easy way to show a Prediction Error Plot

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called prediction_error that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a Prediction Error Plot; example code:
    https://www.scikit-yb.org/en/latest/api/regressor/peplot.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the Prediction Error Plot function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Prediction Error Plot is rendered in example_app.py

Create Column Feature Metrics

What is the Task

Create a function that can render a metrics from a column in dataframe

Why do we want to do this

To provide an easy way to show high level metrics

How can I get started?

  1. Create a new function in data_stats.py called show_metrics that takes in a data frame as a parameter/

  2. Have a drop-down select a column from the dataframe and create the following metrics for a column,

  • mean
  • max
  • min
  • std
  • count

Create 5 st.columns with and use st.metric to show the data

Example code here: https://docs.streamlit.io/en/stable/api.html#streamlit.metric

  1. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/stats/__init__.py

  2. Add the show_metrics function to example_app.py

Definition of Done

Show Metrics is rendered in example_app.py

Add Default fields for functions

What is the Task

Add default fields for options in functions, This can be done over multiple PRs for each function

Why do we want to do this

We want to be able to have pre-rendered visualizations

How can I get started?

  1. Can start with bar_chart function
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L7-L39

  2. Add four Optional parameters

1. selected_x
2. is_x_continuous
3. selected_y
4. selected_z
  1. Add logic to check if the passed in column exists

  2. If the column exists set it as the default value for the corresponding select box

  3. Update examples to render clean visualizations

Definition of Done

Can pass in the optional parameters for each of the functions, and examples updated

Create Interactive 3d Plot Function

What is the Task

Create a function that can render an interactive 3d Plot from a dataframe

Why do we want to do this

To provide an easy way to show a 3d Plot

How can I get started?

  1. Create a new function in charts.py called three_d_plot that takes in a dataframe as a parameter

  2. Have the function provide selectable widgets for the graph axes like this https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L18-L23

  3. Render a 3d Plot with Altair with the selected values, Example code:
    https://plotly.com/python/3d-scatter-plots/

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/__init__.py

  5. Add the 3d Plot function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

3d Plot is rendered in example_app.py

Create a UMAP Corpus Visualization

What is the Task

Create a function that can render a UMAP(Uniform Manifold Approximation and Projection) Corpus Visualization from a dataframe

Why do we want to do this

To provide an easy way to show a UMAP Corpus Visualization

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called umap_viz that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a UMAP Corpus Visualization:
    https://www.scikit-yb.org/en/latest/api/text/umap_vis.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the UMAP Corpus Visualization function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

UMAP Corpus Visualization is rendered in example_app.py

Create Confusion Matrix Function

What is the Task

Create a function that can render a Confusion Matrix from a dataframe

Why do we want to do this

To provide an easy way to show a Confusion Matrix

How can I get started?

  1. Create a new function in yellowbrick_funcs.py called confusion_matrix that takes in a dataframe as a parameter

  2. Leverage the data_prep function to get the dataframe ready https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/yellowbrick_funcs.py#L11

  3. Render a Confusion Matrix, example code:
    https://www.scikit-yb.org/en/latest/api/classifier/confusion_matrix.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/modeling/__init__.py

  5. Add the Confusion Matrix function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Confusion Matrix is rendered in example_app.py

Create Interactive Scatter Plot function

What is the Task

Create a function that can render an interactive scatter plot from a dataframe

Why do we want to do this

To provide an easy way to show a Scatter Plot

How can I get started?

  1. Create a new function in charts.py called scatter_plot that takes in a dataframe as a parameter

  2. Have the function provide selectable widgets for the graph axises like this https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/charts.py#L18-L23

  3. Render a Scatter plot with Altair with the selected values, Example code:
    https://altair-viz.github.io/gallery/simple_line_chart.html

  4. Export the module in __init__.py
    https://github.com/banjtheman/fancylit/blob/main/fancylit/viz/__init__.py

  5. Add the scatter_plot function to example_app.py
    https://github.com/banjtheman/fancylit/blob/main/example_app.py#L23

Definition of Done

Scatter Plot is rendered in example_app.py

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.