init
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import re
|
||||
import os
|
||||
import time
|
||||
import math
|
||||
import sqlite3
|
||||
from datetime import datetime
|
||||
|
||||
@@ -152,7 +153,7 @@ class HTS_Stocks (HTS):
|
||||
|
||||
bs_buy_price = bsLine['buy'][last_index]
|
||||
bs_buy_weight = bsLine['buy_weight'][last_index]
|
||||
buy_count = int(self.MAX_BUY_PRICE / bs_buy_price)
|
||||
buy_count = int(math.ceil(self.MAX_BUY_PRICE / bs_buy_price))
|
||||
if self.MAX_BUY_PRICE <= bs_buy_price < 2 * self.MAX_BUY_PRICE:
|
||||
buy_count = int(2 * self.MAX_BUY_PRICE / bs_buy_price)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user