{"id":28378630,"url":"https://github.com/oriyarden/webull-python-api-stock-market-data-candlestick-plot","last_synced_at":"2026-05-10T05:49:18.661Z","repository":{"id":196281729,"uuid":"695657426","full_name":"OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot","owner":"OriYarden","description":"Plotting candlestick data in Python using Webull's API","archived":false,"fork":false,"pushed_at":"2023-10-02T19:38:18.000Z","size":38,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-30T02:06:58.086Z","etag":null,"topics":["candlestick","candlestick-chart","candlestick-data","google-colab-notebook","matplotlib","numpy","numpy-arrays","pandas","pandas-dataframe","python","stock-data","stock-market","webull","webull-api"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OriYarden.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-23T20:35:48.000Z","updated_at":"2024-08-06T03:22:33.000Z","dependencies_parsed_at":"2023-09-24T02:55:27.695Z","dependency_job_id":null,"html_url":"https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot","commit_stats":null,"previous_names":["oriyarden/webull-python-api-stock-market-data-candlestick-plot"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OriYarden%2FWebull-Python-API-Stock-Market-Data-Candlestick-Plot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OriYarden%2FWebull-Python-API-Stock-Market-Data-Candlestick-Plot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OriYarden%2FWebull-Python-API-Stock-Market-Data-Candlestick-Plot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OriYarden%2FWebull-Python-API-Stock-Market-Data-Candlestick-Plot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OriYarden","download_url":"https://codeload.github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OriYarden%2FWebull-Python-API-Stock-Market-Data-Candlestick-Plot/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":258330230,"owners_count":22684108,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["candlestick","candlestick-chart","candlestick-data","google-colab-notebook","matplotlib","numpy","numpy-arrays","pandas","pandas-dataframe","python","stock-data","stock-market","webull","webull-api"],"created_at":"2025-05-30T02:06:57.952Z","updated_at":"2026-05-10T05:49:18.621Z","avatar_url":"https://github.com/OriYarden.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Webull-Python-API-Stock-Market-Data-Candlestick-Plot\nPlotting candlestick data in Python using Webull's API\n\n\nTo `import` and `login` Webull (plugin your email and account password):\n\n    !pip install webull\n    from webull import webull\n    wb = webull()\n    wb.login('my@email.com', 'password')\n\nTo obtain stock data, we'll use the `get_bars` function and specify the stock's symbol, timeframe, and number of samples (i.e. `stock`, `interval`, and `count`) and save it as a `DataFrame` using `pandas`'s `to_csv` function:\n\n    stock_symbol = 'SPY'\n    stock_data = wb.get_bars(stock=stock_symbol, interval='m1', count=390, extendTrading=0)\n\n    _date = '2023-09-26'\n    file_name = f'/content/drive/My Drive/Colab Notebooks/DATA_FOLDERS/DATA_FRAMES/{stock_symbol}_{_date}.csv'\n    import pandas as pd\n    stock_data.to_csv(file_name)\n\nwhere `'m1'` refers to a one-minute timeframe.\n\nWe'll then retrieve our saved stock data using `pandas`'s `read_csv` function and parse the `timestamp`s into time and date:\n\n    df = pd.read_csv(file_name)\n    \n    def parse_date_from_timestamp(timestamp):\n        return timestamp[:timestamp.find(' ')]\n    \n    def parse_time_from_timestamp(timestamp):\n        def correct_timestamps(timestamp):\n            '''convert timestamp from 24h to 12h'''\n            return timestamp if int(timestamp[:2]) \u003c= 12 else '0' + str(int(timestamp[:2]) - 12) + timestamp[2:]\n        return correct_timestamps(timestamp[timestamp.find(' ') + 1:timestamp.find('-4:') - 5])\n    \n    df['date'] = df.timestamp.map(parse_date_from_timestamp)\n    df['timestamp'] = df.timestamp.map(parse_time_from_timestamp)\n\nWe'll `def`ine a `candlestick_plot_function` to group the data into `numpy` `arrays` and then plot the data as candlesticks using a combination of `BoxStyle`, `FancyBboxPatch`, and `Line2D` `from` `matplotlib`:\n\n    import numpy as np\n    from matplotlib import pyplot as plt\n    from matplotlib.patches import BoxStyle\n    from matplotlib.patches import FancyBboxPatch\n    from matplotlib.lines import Line2D\n\n    def candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=30, wick_linewidth=2.0, fancy_box_padding=0.0005):\n        def calc_num_candlesticks(df, candlestick_size_in_minutes):\n            return int(df.index.stop / candlestick_size_in_minutes) if df.index.stop / candlestick_size_in_minutes == int(df.index.stop / candlestick_size_in_minutes) else int(df.index.stop / candlestick_size_in_minutes) + 1\n    \n        def calc_box_width(num_candlesticks):\n            return 0.98 - (num_candlesticks / 125)\n    \n        def remove_prefixed_zero(timestamp):\n            return timestamp[:5] if timestamp[0] != '0' else timestamp[1:5]\n    \n        y = np.zeros((calc_num_candlesticks(df, candlestick_size_in_minutes), 4)).astype(float)\n        box_width = calc_box_width(y.shape[0])\n    \n        ax.set_facecolor([0, 0, 0.35])\n        ax.grid(which='major', axis='both', color=[1, 1, 1], linewidth=0.5, zorder=0)\n        for candlestick in range(y.shape[0]):\n            indexes_per_candlestick = range(candlestick*candlestick_size_in_minutes, (candlestick + 1)*candlestick_size_in_minutes, 1)\n            if indexes_per_candlestick.stop \u003e df.index.stop:\n                indexes_per_candlestick = range(candlestick*candlestick_size_in_minutes, df.index.stop, 1)\n            data = df.iloc[indexes_per_candlestick]\n            y[candlestick, :] = np.array([data.open.iloc[0], np.max(data.high), np.min(data.low), data.close.iloc[-1]])\n    \n            top_of_box = np.max([y[candlestick, 0], y[candlestick, 3]])\n            bottom_of_box = np.min([y[candlestick, 0], y[candlestick, 3]])\n            box_color = np.array([0.0, 0.8, 0.6941]) if y[candlestick, 0] \u003c y[candlestick, 3] else np.array([1.0, 0.0, 0.0])\n    \n            ax.add_line(Line2D(xdata=(candlestick, candlestick), ydata=(y[candlestick, 2], bottom_of_box), color=box_color, linewidth=wick_linewidth, antialiased=True, zorder=2))\n            ax.add_line(Line2D(xdata=(candlestick, candlestick), ydata=(y[candlestick, 1], bottom_of_box), color=box_color, linewidth=wick_linewidth, antialiased=True, zorder=2))\n            ax.add_patch(FancyBboxPatch(xy=(candlestick - box_width*0.5, bottom_of_box), width=box_width, height=top_of_box - bottom_of_box, facecolor=box_color, edgecolor=box_color, boxstyle=BoxStyle('round', pad=fancy_box_padding), zorder=2))\n    \n        ax.set_ylim(np.min(y) - 0.1*(np.max(y) - np.min(y)), np.max(y) + 0.1*(np.max(y) - np.min(y)))\n        ax.set_xlim(-0.1*y.shape[0], y.shape[0] + 0.1*y.shape[0])\n        ax.set_title(f'''\n            {stock_symbol}\n            {candlestick_size_in_minutes} Minute Candlesticks''', fontsize=15, fontweight='bold')\n        ax.set_yticks([_y for _y in ax.get_yticks()][1:-1])\n        ax.set_yticklabels(['{:.2f}'.format(_y) for _y in ax.get_yticks()])\n        ax.set_xticks([0, int(y.shape[0]*0.5), y.shape[0] - 1])\n        ax.set_xticklabels([remove_prefixed_zero(df.timestamp.values[0]), remove_prefixed_zero(df.timestamp.values[int(df.timestamp.values.shape[0]*0.5)]), remove_prefixed_zero(df.timestamp.values[-1])])\n        for axis in ['left', 'right', 'top', 'bottom']:\n            ax.spines[axis].set_visible(False) if axis in ['top', 'right'] else ax.spines[axis].set_linewidth(5)\n        for label in (ax.get_xticklabels() + ax.get_yticklabels()):\n            label.set_fontsize(15)\n            label.set_fontweight('bold')\n    \n    fig = plt.figure(figsize=(5, 5))\n    ax = plt.subplot(1, 1, 1)\n    candlestick_plot_function(fig, ax, df, stock_symbol)\n    plt.show()\n\n\nWhich creates a 30-minute candlesticks plot:\n\n![image](https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/assets/137197657/8de61b45-b5fd-43ad-810b-de800d044085)\n\n\nWe can also adjust the `candlestick_size_in_minutes` parameter to plot different timeframes; for example 10-minute candlesticks:\n\n    fig = plt.figure(figsize=(5, 5))\n    ax = plt.subplot(1, 1, 1)\n    candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=10, wick_linewidth=1.0)\n    plt.show()\n\n![image](https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/assets/137197657/6e5ceabe-94d9-420d-8cff-31043268ff43)\n\n\nor 60-minute candlesticks:\n\n    fig = plt.figure(figsize=(5, 5))\n    ax = plt.subplot(1, 1, 1)\n    candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=60)\n    plt.show()\n\n\n![image](https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/assets/137197657/d859c8b2-5db5-48aa-b13f-1b21e99ce86e)\n\n\n\n# Grouping Candlesticks by Timestamp in a Vectorized Process:\n\n\nFirst we need a `list` of start and stop times as hour and minute `int`egers that can span across one or more days:\n\n    def get_candlesticks(df, candlestick_size_in_minutes=30):\n        '''returns a list of pairs of time stamps as integers [hour (start), minute (start), next hour (stop), next minute (stop)] from 9:30am up to (but not including) 4:00pm grouped by the candlestick_size_in_minutes parameter'''\n        __hour = df.hour.iloc[0]\n        def round_minute_down(__minute, candlestick_size_in_minutes):\n            candlesticks = np.arange(0, 60 + candlestick_size_in_minutes, candlestick_size_in_minutes).astype(int)\n            first_candlestick = np.where(np.abs(candlesticks - __minute) == np.min(np.abs(candlesticks - __minute)))\n            if candlesticks[first_candlestick] \u003e __minute:\n                first_candlestick[0][0] -= 1\n            return candlesticks[first_candlestick[0][0]]\n\n        __minute = round_minute_down(df.minute.iloc[0], candlestick_size_in_minutes)\n        __date = 0\n        candlesticks = [[__hour, __minute, __hour + 1 if __minute + candlestick_size_in_minutes \u003e 60 else __hour, min(__minute + candlestick_size_in_minutes, 60), np.unique(np.array(df.date))[__date]]]\n        for _ in range(int((390 - candlestick_size_in_minutes) / candlestick_size_in_minutes)*np.unique(np.array(df.date)).shape[0]):\n            __minute += candlestick_size_in_minutes\n            if __minute \u003e= 60:\n                __minute -= 60\n                __hour += 1\n            if __hour == 13:\n                __hour = 1\n            if __hour == 4:\n                __hour = 9\n                __minute = 30\n                __date += 1\n            if __date \u003e= np.unique(np.array(df.date)).shape[0] - 1 and candlesticks[-1][1] \u003c= df.minute.iloc[-1] \u003c candlesticks[-1][3] and candlesticks[-1][0] == df.hour.iloc[-1] and candlesticks[-1][4] == df.date.iloc[-1]:\n                return candlesticks\n            candlesticks.append([__hour, __minute, __hour + 1 if __minute + candlestick_size_in_minutes \u003e 60 else __hour, min(__minute + candlestick_size_in_minutes, 60), df.date.iloc[0] if np.unique(np.array(df.date)).shape[0] == 1 else np.unique(np.array(df.date))[min(__date, np.unique(np.array(df.date)).shape[0] - 1)]])\n        return candlesticks\n\n\nWe'll then `def`ine a function that `return`s `True` for indexes that fall between the start and stop hours and minutes `list` and match the correct `'date'`:\n\n    def is_a_candlestick(df_hours, df_minutes, _hour, _minute, _next_hour, _next_minute, df_date, _date):\n        '''returns True for timestamps ([hour, minute]) that match the correct candlestick; conditions vectorized for numpy.where() function'''\n        if all([df_date == _date, df_hours == _hour, _hour == _next_hour, df_minutes \u003e= _minute, df_minutes \u003c _next_minute]) or all([df_date == _date, df_hours == _hour, _hour != _next_hour, df_minutes \u003e= _minute, df_minutes \u003c _next_minute if _minute \u003c _next_minute else True]) or all([df_date == _date, df_hours == _next_hour, _next_minute != 60, df_minutes \u003c _next_minute, df_minutes \u003e= _minute if _minute \u003c _next_minute else True]):\n            return True\n\n    is_a_candlestick = np.vectorize(is_a_candlestick)\n\n\nWhat `numpy`'s `vectorize` function does is it allows us to `def`ine a function hook into which another `numpy` function can get as a vectorized input. In the simplest case, which we did, is use an `if-statement` that `return`s `True`, which when passed to `numpy`'s `where()` function, will provide us the indexes that meet our condition(s), without having to iterate through each one:\n\n    for candlestick, (_hour, _minute, _next_hour, _next_minute, _date) in enumerate(candlesticks):\n        indexes = np.where(is_a_candlestick(np.array(df.hour), np.array(df.minute), _hour, _minute, _next_hour, _next_minute, np.array(df.date), _date))\n        y[candlestick, :] = np.array([df.open.iloc[indexes].iloc[0], np.max(df.high.iloc[indexes]), np.min(df.low.iloc[indexes]), df.close.iloc[indexes].iloc[-1]])\n\n\nAltogether we have:\n\n    import numpy as np\n    from matplotlib import pyplot as plt\n    from matplotlib.patches import BoxStyle\n    from matplotlib.patches import FancyBboxPatch\n    from matplotlib.lines import Line2D\n    \n    def candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=30, wick_linewidth=2.0, fancy_box_padding=0.0005):\n        def get_candlesticks(df, candlestick_size_in_minutes=30):\n            '''returns a list of pairs of time stamps as integers [hour (start), minute (start), next hour (stop), next minute (stop)] from 9:30am up to (but not including) 4:00pm grouped by the candlestick_size_in_minutes parameter'''\n            __hour = df.hour.iloc[0]\n            def round_minute_down(__minute, candlestick_size_in_minutes):\n                candlesticks = np.arange(0, 60 + candlestick_size_in_minutes, candlestick_size_in_minutes).astype(int)\n                first_candlestick = np.where(np.abs(candlesticks - __minute) == np.min(np.abs(candlesticks - __minute)))\n                if candlesticks[first_candlestick] \u003e __minute:\n                    first_candlestick[0][0] -= 1\n                return candlesticks[first_candlestick[0][0]]\n    \n            __minute = round_minute_down(df.minute.iloc[0], candlestick_size_in_minutes)\n            __date = 0\n            candlesticks = [[__hour, __minute, __hour + 1 if __minute + candlestick_size_in_minutes \u003e 60 else __hour, min(__minute + candlestick_size_in_minutes, 60), np.unique(np.array(df.date))[__date]]]\n            for _ in range(int((390 - candlestick_size_in_minutes) / candlestick_size_in_minutes)*np.unique(np.array(df.date)).shape[0]):\n                __minute += candlestick_size_in_minutes\n                if __minute \u003e= 60:\n                    __minute -= 60\n                    __hour += 1\n                if __hour == 13:\n                    __hour = 1\n                if __hour == 4:\n                    __hour = 9\n                    __minute = 30\n                    __date += 1\n                if __date \u003e= np.unique(np.array(df.date)).shape[0] - 1 and candlesticks[-1][1] \u003c= df.minute.iloc[-1] \u003c candlesticks[-1][3] and candlesticks[-1][0] == df.hour.iloc[-1] and candlesticks[-1][4] == df.date.iloc[-1]:\n                    return candlesticks\n                candlesticks.append([__hour, __minute, __hour + 1 if __minute + candlestick_size_in_minutes \u003e 60 else __hour, min(__minute + candlestick_size_in_minutes, 60), df.date.iloc[0] if np.unique(np.array(df.date)).shape[0] == 1 else np.unique(np.array(df.date))[min(__date, np.unique(np.array(df.date)).shape[0] - 1)]])\n            return candlesticks\n    \n        def calc_box_width(num_candlesticks):\n            '''returns a box_width value such that candlesticks are close together but not touching or overlapping'''\n            return 0.98 - (num_candlesticks / 125)\n    \n        def remove_prefixed_zero(timestamp):\n            '''returns for example \"9:30\" in place of \"09:30\"'''\n            return timestamp[:5] if timestamp[0] != '0' else timestamp[1:5]\n    \n        def is_a_candlestick(df_hours, df_minutes, _hour, _minute, _next_hour, _next_minute, df_date, _date):\n            '''returns True for timestamps ([hour, minute]) that match the correct candlestick; conditions vectorized for numpy.where() function'''\n            if all([df_date == _date, df_hours == _hour, _hour == _next_hour, df_minutes \u003e= _minute, df_minutes \u003c _next_minute]) or all([df_date == _date, df_hours == _hour, _hour != _next_hour, df_minutes \u003e= _minute, df_minutes \u003c _next_minute if _minute \u003c _next_minute else True]) or all([df_date == _date, df_hours == _next_hour, _next_minute != 60, df_minutes \u003c _next_minute, df_minutes \u003e= _minute if _minute \u003c _next_minute else True]):\n                return True\n    \n        is_a_candlestick = np.vectorize(is_a_candlestick)\n    \n        candlesticks = get_candlesticks(df, candlestick_size_in_minutes)\n        y = np.zeros((len(candlesticks), 4)).astype(float)\n        box_width = calc_box_width(y.shape[0])\n    \n        ax.set_facecolor([0, 0, 0.35])\n        ax.grid(which='major', axis='both', color=[1, 1, 1], linewidth=0.5, zorder=0)\n        for candlestick, (_hour, _minute, _next_hour, _next_minute, _date) in enumerate(candlesticks):\n            indexes = np.where(is_a_candlestick(np.array(df.hour), np.array(df.minute), _hour, _minute, _next_hour, _next_minute, np.array(df.date), _date))\n            y[candlestick, :] = np.array([df.open.iloc[indexes].iloc[0], np.max(df.high.iloc[indexes]), np.min(df.low.iloc[indexes]), df.close.iloc[indexes].iloc[-1]])\n    \n            top_of_box = np.max([y[candlestick, 0], y[candlestick, 3]])\n            bottom_of_box = np.min([y[candlestick, 0], y[candlestick, 3]])\n            box_color = np.array([0.0, 0.8, 0.6941]) if y[candlestick, 0] \u003c y[candlestick, 3] else np.array([1.0, 0.0, 0.0])\n    \n            ax.add_line(Line2D(xdata=(candlestick, candlestick), ydata=(y[candlestick, 2], bottom_of_box), color=box_color, linewidth=wick_linewidth, antialiased=True, zorder=2))\n            ax.add_line(Line2D(xdata=(candlestick, candlestick), ydata=(y[candlestick, 1], bottom_of_box), color=box_color, linewidth=wick_linewidth, antialiased=True, zorder=2))\n            ax.add_patch(FancyBboxPatch(xy=(candlestick - box_width*0.5, bottom_of_box), width=box_width, height=top_of_box - bottom_of_box, facecolor=box_color, edgecolor=box_color, boxstyle=BoxStyle('round', pad=fancy_box_padding), zorder=2))\n    \n        ax.set_ylim(np.min(y) - 0.1*(np.max(y) - np.min(y)), np.max(y) + 0.1*(np.max(y) - np.min(y)))\n        ax.set_xlim(-0.1*y.shape[0], y.shape[0] + 0.1*y.shape[0])\n        ax.set_title(f'''\n            {stock_symbol}\n            {candlestick_size_in_minutes} Minute Candlesticks''', fontsize=15, fontweight='bold')\n        ax.set_yticks([_y for _y in ax.get_yticks()][1:-1])\n        ax.set_yticklabels(['{:.2f}'.format(_y) for _y in ax.get_yticks()])\n        ax.set_xticks([0, int(y.shape[0]*0.5), y.shape[0] - 1])\n        ax.set_xticklabels([remove_prefixed_zero(df.timestamp.values[0]), remove_prefixed_zero(df.timestamp.values[int(df.timestamp.values.shape[0]*0.5)]), remove_prefixed_zero(df.timestamp.values[-1])])\n        for axis in ['left', 'right', 'top', 'bottom']:\n            ax.spines[axis].set_visible(False) if axis in ['top', 'right'] else ax.spines[axis].set_linewidth(5)\n        for label in (ax.get_xticklabels() + ax.get_yticklabels()):\n            label.set_fontsize(15)\n            label.set_fontweight('bold')\n    \n    stock_symbol = 'SPY'\n    _date = '2023-09-27'\n    \n    file_name = f'/content/drive/My Drive/Colab Notebooks/DATA_FOLDERS/DATA_FRAMES/{stock_symbol}_{_date}.csv'\n    \n    import pandas as pd\n    df = pd.read_csv(file_name)\n    \n    def parse_date_from_timestamp(timestamp):\n        return timestamp[:timestamp.find(' ')]\n    \n    def parse_time_from_timestamp(timestamp):\n        def correct_timestamps(timestamp):\n            '''convert timestamp from 24h to 12h'''\n            return timestamp if int(timestamp[:2]) \u003c= 12 else '0' + str(int(timestamp[:2]) - 12) + timestamp[2:]\n        return correct_timestamps(timestamp[timestamp.find(' ') + 1:timestamp.find('-4:') - 5])\n    \n    df['date'] = df.timestamp.map(parse_date_from_timestamp)\n    df['timestamp'] = df.timestamp.map(parse_time_from_timestamp)\n    \n    def get_hour(timestamp):\n        return int(timestamp[:2])\n    \n    def get_minute(timestamp):\n        return int(timestamp[3:5])\n    \n    df['hour'] = df.timestamp.map(get_hour)\n    df['minute'] = df.timestamp.map(get_minute)\n    \n    fig = plt.figure(figsize=(5, 5))\n    ax = plt.subplot(1, 1, 1)\n    candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=30)\n    plt.show()\n\n\n![image](https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/assets/137197657/487f8960-ca21-4876-ae15-1846ed82ecfd)\n\n\n    fig = plt.figure(figsize=(5, 5))\n    ax = plt.subplot(1, 1, 1)\n    candlestick_plot_function(fig, ax, df, stock_symbol, candlestick_size_in_minutes=60)\n    plt.show()\n\n\n![image](https://github.com/OriYarden/Webull-Python-API-Stock-Market-Data-Candlestick-Plot/assets/137197657/179392a6-573e-4688-99aa-97e075a5961c)\n\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foriyarden%2Fwebull-python-api-stock-market-data-candlestick-plot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foriyarden%2Fwebull-python-api-stock-market-data-candlestick-plot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foriyarden%2Fwebull-python-api-stock-market-data-candlestick-plot/lists"}