Skip to content

Feature Request: Combination of Candle Stick Chart With Option Chain Pyramid #595

@DrChandrakant

Description

@DrChandrakant

Many Traders Looking For This Feature Where Option Chain Pyramid Need To Plot On Candle Stick Chart
download

I Attempted This With Small Piece of Code. Please Take a Look.

Call = vb['call']
Put = vb['put']
width = 0.4
fig, axlist = mpf.plot(df,type='candle', returnfig=True, tight_layout=True, volume=True, style="yahoo",)
size = 0.0012 * max(df['Close'])
pyramid = fig.add_axes(axlist[0].get_position())
pyramid.set_axis_off()
pyramid.set_xlim(right=1.2*max(Call.values))

pyramid.barh( Call.keys().values, Call.values,height=0.02*size, color='red', alpha=0.20)
pyramid.barh( Put.keys().values+width, Put.values,height=0.02*size, color='green', alpha=0.20)
pyramid.invert_xaxis()
mpl.show()

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions