Metadata-Version: 2.1
Name: ing_theme_matplotlib
Version: 0.1.2
Summary: ING styles for common plotting libraries
Home-page: https://gitlab.com/ing_rpaa/ing_theme_matplotlib
Author: Ahmet Emre Bayraktar - ING
Author-email: aemrebayraktar@gmail.com
License: Apache 2.0
Description: # ING Style Plotting
        
        [![License](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
        
        ing_theme_matplotlib is a python package with a light and a dark [`matplotlib`](https://github.com/matplotlib/matplotlib) style that allows you to create your plots using ING colors. It was adapted from the [`qbstyles`](https://github.com/quantumblacklabs/qbstyles) package.
        
        Dark style | Light style
        |-----------|----------- |
        | ![Scatter plot](https://gitlab.com/ing_rpaa/ing_theme_matplotlib/uploads/e695ba1c207af8045d5117c8cb84690e/scatter_dark.png "Scatter plot") | ![Distribution plot](https://gitlab.com/ing_rpaa/ing_theme_matplotlib/uploads/c649e6457e47ea70e21cf214b02180cb/dist_light.png "Distribution plot") |
        
        ## How to install ing_theme_matplotlib
        
        `ing_theme_matplotlib` is a Python package. To install it, simply run:
        
        
        ```bash
        pip install ing_theme_matplotlib
        ```
        
        ## How to use ING Style Plotting
        
        You can use the dark Matplotlib style theme in the following way:
        
        ```python
        from ing_theme_matplotlib import mpl_style
        ```
        ```python
        mpl_style(dark=True)
        ```
        
        And to use the light Matplotlib style theme, you can do the following: 
        
        ```python
        from ing_theme_matplotlib import mpl_style
        ```
        ```python
        mpl_style(dark=False)
        ```
        > ⚠️ Please make sure you run `from ing_theme_matplotlib import mpl_style` and `mpl_style()` in **different cells** as shown above. See [this issue](https://github.com/jupyter/notebook/issues/3691) for more details.
        
        ## How to add ING Logo to the plots
        
        Assume that below is the function we use for plotting;
        
        ```python
        def line_plot(ax):
            rng = np.random.RandomState(4)
            x = np.linspace(0, 10, 500)
            y = np.cumsum(rng.randn(500, 4), 0)
            ax.set_title('Line Graph')
            ax.set_xlabel('— Time')
            ax.set_ylabel('— Random values')
            ax.plot(x, y, label = ['Bitcoin', 'Ethereum', 'Dollar', 'Oil'])
            ax.legend(['Bitcoin', 'Ethereum', 'Dollar', 'Oil'], loc = 1, fontsize = 'medium')
            ax.set_xlim([0, 10])
            ax.set_ylim([-20, 60])
            ax.figure.set_figwidth(16)
            ax.figure.set_figheight(8)
            ax.spines['right'].set_position(('axes', 1.05))
            ax.spines['right'].set_color('none')
        ```
        
        You can add the default ing logo to your plot by calling add_logo function inside the plotting function.
        ```python
        from ing_theme_matplotlib.mpl_style import add_logo
        ```
        ```python
        mpl_style()
        line_plot(add_logo())
        ```
        ![png](https://gitlab.com/ing_rpaa/ing_theme_matplotlib/uploads/4dc42be877ec45cfb9fabef46c33242f/line_dark_ing_logo.png)
        
        You can also add custom logos to your plot by giving the path where the image is located.
        ```python
        from ing_theme_matplotlib.mpl_style import add_logo
        ```
        ```python
        mpl_style(dark = False)
        line_plot(add_logo(bottom_left = 'logos/RPAA_Logo_RGB_Line.png'))
        ```
        ![png](https://gitlab.com/ing_rpaa/ing_theme_matplotlib/uploads/fb31ccc66d5bd14a6c1ecfcf6a714f9e/line_light_custom_logo.png)
        
        For more examples, you can check out the [`ExamplePlots.ipynb`](ExamplePlots.ipynb) file.
        
        ## What chart types can be used with ing_theme_matplotlib?
        
        - Line plots
        - Scatter plots
        - Bubble plots
        - Bar charts
        - Pie charts
        - Histograms and distribution plots
        - 3D surface plots
        - Stream plots
        - Polar plots
        
        ## What licence do we use?
        
        ING Style plotting is licensed under the [Apache 2.0 License](https://www.apache.org/licenses/LICENSE-2.0).
        
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.5
Description-Content-Type: text/markdown
