Skip to content

Commit 56af314

Browse files
committed
Raise exception when using addplot w/ renko
1 parent 3f3ce99 commit 56af314

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/mplfinance/plotting.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,10 @@ def plot( data, **kwargs ):
161161
dates,opens,highs,lows,closes,volumes = _check_and_prepare_data(data)
162162

163163
config = _process_kwargs(kwargs, _valid_plot_kwargs())
164+
165+
if config['type'] == 'renko' and config['addplot'] is not None:
166+
err = "`addplot` is not supported for `type='renko'`"
167+
raise ValueError(err)
164168

165169
style = config['style']
166170
if isinstance(style,str):

0 commit comments

Comments
 (0)