init
This commit is contained in:
@@ -16,6 +16,14 @@ class MonitorCoin (Monitor):
|
||||
data = self.get_coin_some_data(symbol, interval)
|
||||
if data is not None and not data.empty:
|
||||
try:
|
||||
inverseData = self.inverse_data(data)
|
||||
recent_inverseData = self.check_buy_point(symbol, inverseData)
|
||||
if recent_inverseData['sell_point'].iloc[-1] != 1:
|
||||
return
|
||||
sell_success = self.sell_ticker(symbol, recent_inverseData)
|
||||
if not sell_success:
|
||||
return
|
||||
|
||||
data = self.calculate_technical_indicators(data)
|
||||
recent_data = self.check_buy_point(symbol, data)
|
||||
if recent_data['buy_point'].iloc[-1] != 1:
|
||||
@@ -23,9 +31,6 @@ class MonitorCoin (Monitor):
|
||||
buy_success = self.buy_ticker(symbol, recent_data)
|
||||
if not buy_success:
|
||||
return
|
||||
sell_success = self.sell_ticker(symbol, recent_data)
|
||||
if not sell_success:
|
||||
return
|
||||
except Exception as e:
|
||||
print(f"Error processing data for {symbol}: {str(e)}")
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user