Search code examples
matplotlibmplfinancelinewidth

Matplotlib / Mplfinance - how to change line width


maybe someone knows what I need add here to change line width?

mpf.plot(df4, type='candle', style='yahoo', volume=True, hlines=[12,4],  )

Solution

  • Vertical and horizontal lines can be set in dictionary format. Line widths are specified in tuple format.

    mpf.plot(df, 
             type='candle',
             style='yahoo',
             volume=True, 
             hlines=dict(hlines=[12,4], linewidths=(2,3.5)))
    

    enter image description here