Use correct long and neutral signal abbreviations in 2-period RSI strategy
This commit is contained in:
parent
0d2afb2036
commit
a2649a5e48
@ -32,4 +32,4 @@ def signals(data: DataFrame) -> Series:
|
|||||||
rsi_2 = calculate_rsi(data)
|
rsi_2 = calculate_rsi(data)
|
||||||
|
|
||||||
conditions = (data['Close'] > ma_200) & (rsi_2 < 5)
|
conditions = (data['Close'] > ma_200) & (rsi_2 < 5)
|
||||||
return Series(np.where(conditions, 'Long', 'None'), index = data.index)
|
return Series(np.where(conditions, 'L', 'N'), index = data.index)
|
Loading…
Reference in New Issue
Block a user