init
This commit is contained in:
@@ -577,11 +577,14 @@ class Common:
|
|||||||
if len(stock['trend']) < 1:
|
if len(stock['trend']) < 1:
|
||||||
return check
|
return check
|
||||||
|
|
||||||
|
if (stock['close'][1] is None or stock['close'][0] is None or stock['rsi'][1] is None or stock['rsi'][0] is None):
|
||||||
|
return check
|
||||||
|
|
||||||
rise_rate = param['bull'][0] / (param['bull'][0]+param['bear'][0]+param['bull'][0])
|
rise_rate = param['bull'][0] / (param['bull'][0]+param['bear'][0]+param['bull'][0])
|
||||||
if (
|
if (
|
||||||
((stock['macd'][1] is not None and stock['macd'][0] is not None) and stock['macd'][1] < stock['macd'][0] and stock['rsi'][0] < 80) or
|
(stock['macd'][1] < stock['macd'][0] and stock['rsi'][0] < 80) or
|
||||||
((stock['rsi'][1] is not None and stock['rsi'][0] is not None) and stock['rsi'][1] < stock['rsi'][0] and np.min(stock['rsi'][:3]) < 35) or
|
(stock['rsi'][1] < stock['rsi'][0] and np.min(stock['rsi'][:3]) < 35) or
|
||||||
((stock['rsi'][0] is not None) and stock['rsi'][0] < 35) or
|
(stock['rsi'][0] < 35) or
|
||||||
0.7 <= rise_rate
|
0.7 <= rise_rate
|
||||||
):
|
):
|
||||||
# avg300 상승
|
# avg300 상승
|
||||||
@@ -613,7 +616,7 @@ class Common:
|
|||||||
buy_type = "rsi"
|
buy_type = "rsi"
|
||||||
check = True
|
check = True
|
||||||
|
|
||||||
if (stock['rsi'][1] is not None and stock['rsi'][0] is not None) and not(stock['rsi'][1] < stock['rsi'][0] and stock['rsis'][0] < stock['rsi'][0]):
|
if not(stock['rsi'][1] < stock['rsi'][0] and stock['rsis'][0] < stock['rsi'][0]):
|
||||||
check = False
|
check = False
|
||||||
|
|
||||||
return check
|
return check
|
||||||
|
|||||||
Reference in New Issue
Block a user