init
This commit is contained in:
@@ -69,9 +69,10 @@ class HTS_122630 (HTS):
|
||||
|
||||
print ("START...")
|
||||
THIS_TIME = datetime.now()
|
||||
while datetime.strptime(today + " 070000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 15200", '%Y%m%d %H%M%S'):
|
||||
final_sell_check = False
|
||||
while datetime.strptime(today + " 070000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 153100", '%Y%m%d %H%M%S'):
|
||||
|
||||
if datetime.strptime(today + " 090100", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151500", '%Y%m%d %H%M%S'):
|
||||
if datetime.strptime(today + " 090000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151500", '%Y%m%d %H%M%S'):
|
||||
if THIS_TIME.strftime('%Y%m%d %H%M%S') in timecheck and not timecheck[THIS_TIME.strftime('%Y%m%d %H%M%S')]:
|
||||
|
||||
# 데이터를 가지고 온다.
|
||||
@@ -135,7 +136,10 @@ class HTS_122630 (HTS):
|
||||
data["rsi"][data_size - 1], data["rsis"][data_size - 1]))
|
||||
timecheck[THIS_TIME] = True
|
||||
|
||||
if datetime.strptime(today + " 151530", '%Y%m%d %H%M%S') < THIS_TIME:
|
||||
elif datetime.strptime(today + " 151530", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151600", '%Y%m%d %H%M%S'):
|
||||
if final_sell_check:
|
||||
continue
|
||||
|
||||
####
|
||||
# 손해 보지 않는 가격에 매도한다.
|
||||
####
|
||||
@@ -155,7 +159,7 @@ class HTS_122630 (HTS):
|
||||
# 로그 출력
|
||||
print("SELL", THIS_TIME, selling_count, selling_price)
|
||||
|
||||
break
|
||||
final_sell_check = True
|
||||
|
||||
time.sleep(0.9)
|
||||
THIS_TIME = datetime.now()
|
||||
|
||||
@@ -69,9 +69,10 @@ class HTS_252670 (HTS):
|
||||
|
||||
print ("START...")
|
||||
THIS_TIME = datetime.now()
|
||||
while datetime.strptime(today + " 070000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 15200", '%Y%m%d %H%M%S'):
|
||||
final_sell_check = False
|
||||
while datetime.strptime(today + " 070000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 153100", '%Y%m%d %H%M%S'):
|
||||
|
||||
if datetime.strptime(today + " 090100", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151500", '%Y%m%d %H%M%S'):
|
||||
if datetime.strptime(today + " 090000", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151500", '%Y%m%d %H%M%S'):
|
||||
if THIS_TIME.strftime('%Y%m%d %H%M%S') in timecheck and not timecheck[THIS_TIME.strftime('%Y%m%d %H%M%S')]:
|
||||
|
||||
# 데이터를 가지고 온다.
|
||||
@@ -136,7 +137,10 @@ class HTS_252670 (HTS):
|
||||
|
||||
timecheck[THIS_TIME] = True
|
||||
|
||||
if datetime.strptime(today + " 151530", '%Y%m%d %H%M%S') < THIS_TIME:
|
||||
elif datetime.strptime(today + " 151530", '%Y%m%d %H%M%S') < THIS_TIME < datetime.strptime(today + " 151600", '%Y%m%d %H%M%S'):
|
||||
if final_sell_check:
|
||||
continue
|
||||
|
||||
####
|
||||
# 손해 보지 않는 가격에 매도한다.
|
||||
####
|
||||
@@ -156,7 +160,7 @@ class HTS_252670 (HTS):
|
||||
# 로그 출력
|
||||
print("SELL", THIS_TIME, selling_count, selling_price)
|
||||
|
||||
break
|
||||
final_sell_check = True
|
||||
|
||||
time.sleep(0.9)
|
||||
THIS_TIME = datetime.now()
|
||||
|
||||
Reference in New Issue
Block a user