init
This commit is contained in:
@@ -186,7 +186,7 @@ if __name__ == "__main__":
|
||||
|
||||
# KODEX 인버스 * 2
|
||||
stock_code = "122630"
|
||||
buy_count = 40
|
||||
buy_count = 50
|
||||
|
||||
hts = HTS_122630(stock_code, buy_count)
|
||||
today_str = today.strftime('%Y%m%d')
|
||||
|
||||
@@ -155,9 +155,6 @@ class HTS_252670 (HTS):
|
||||
# 3시 15분 30초부터 3시 16분 사이는 잔량을 매도한다.
|
||||
|
||||
if not final_sell_check:
|
||||
####
|
||||
# 손해 보지 않는 가격에 매도한다.
|
||||
####
|
||||
|
||||
# 주문 리스트를 가져온다.
|
||||
orderList = self.requestOrderList()
|
||||
@@ -167,7 +164,8 @@ class HTS_252670 (HTS):
|
||||
# 매도 가격을 가져온다.
|
||||
result = self.getRealTime(self.stock_code, lastday, today)
|
||||
final_price = result["close"][len(result["close"]) - 1]
|
||||
selling_count, selling_price = self.getFinalSellingPrice(final_price)
|
||||
#selling_count, selling_price = self.getFinalSellingPrice(final_price)
|
||||
selling_count, selling_price = self.getSellingPrice(final_price)
|
||||
# 분석되 가격으로 매도 요청한다.
|
||||
if selling_count != 0 and selling_price != 0:
|
||||
orderNum = self.requestOrder(OrderType.sell, self.stock_code, selling_count, selling_price)
|
||||
@@ -190,7 +188,7 @@ if __name__ == "__main__":
|
||||
|
||||
# KODEX 인버스 * 2
|
||||
stock_code = "252670"
|
||||
buy_count = 300
|
||||
buy_count = 200
|
||||
|
||||
hts = HTS_252670(stock_code, buy_count)
|
||||
today_str = today.strftime('%Y%m%d')
|
||||
|
||||
Reference in New Issue
Block a user