回答編集履歴

1

Update

2022/05/30 16:33

投稿

melian
melian

スコア19825

test CHANGED
@@ -2,8 +2,9 @@
2
2
  ```python
3
3
  import mplfinance as mpf
4
4
 
5
- markers = df_stock['entry'].astype(str).str.replace(r'^(.*)$', r'$\1$', regex=True).values
5
+ markers = df_stock['entry'].map('${}$'.format).values
6
6
  adp = mpf.make_addplot(1.003*df_stock['High'], type='scatter', marker=markers, markersize=150)
7
+ mpf.plot(df_stock, type = 'candle', figratio = (10, 5), addplot=adp,
7
- mpf.plot(df_stock, type = 'candle', figratio = (10, 5), addplot=adp, scale_padding={'left': 0.2, 'right': 0.1, 'top': 0.1, 'bottom': 0.5})
8
+ scale_padding={'left': 0.2, 'right': 0.1, 'top': 0.1, 'bottom': 0.5})
8
9
  ```
9
10
  ![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-05-30/38544cd0-1f39-4366-a029-46985cbf0947.png)