trading bot


SUBMITTED BY: Guest

DATE: Jan. 13, 2015, 12:49 a.m.

FORMAT: Python

SIZE: 525 Bytes

HITS: 875

  1. # Donations: 16RdQZ86NUWQbE6rM86JbxnnaCDcAKqa9
  2. def getTrend():
  3. return getCurrentPrice()-getOldPrice()
  4. def chekMax():
  5. if getOldTrend()>0 and getCurrentTrend()<0:
  6. return True
  7. return False
  8. def checkMax():
  9. if getOldTrend()<0 and getCurrentTrend()>0:
  10. return True
  11. return False
  12. def action():
  13. if getTrend()>O and checkMin():
  14. buy(0.01)
  15. else if getTrend()<0 and checkMax():
  16. sell(0.01)
  17. Timer(300, action, ()).start()

comments powered by Disqus