Bitcoin Forum
May 07, 2024, 12:41:53 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: 1 2 3 4 5 [All]
  Print  
Author Topic: tAPI-bot - Automated crossover trade platform for BTC-e [INACTIVE 2013-10-15]  (Read 36322 times)
nomorecoin (OP)
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
May 07, 2013, 02:43:37 AM
Last edit: October 15, 2013, 11:09:50 PM by nomorecoin
 #1

I have decided to open source my trade "bot". It is written in Python 2.7, and uses Pylab (or matplotlib+numpy, confirmed) for graphing output. I have not tested without these packages.
I use the EPD free distribution of Python 2.7.3, which is available here, though all that should be required is Pylab, and only if you wish to view a simple plot of the lines the bot "sees".

The trade algorithm is very simple, but fairly configurable. It uses a moving average crossover with several options. See settings.ini.
I expect there are more than a few issues. Logging is incomplete, and error handling is nearly non-existent. Run in IDLE for better stack traces.
Only trades against BTC-e (for now).

One other note, the program uses individual trades as periods for the purpose of moving averages. This is non-typical, and may not align with traditional wisdom for crossover signals.

Grab the source as a zip from my Github, extract, punch in some API stuff, configure your signals, and run Application.py to start.

pre-posting edit: it seems EPD free has been renamed to "Canopy" something or other. Should work just as well.
1715085713
Hero Member
*
Offline Offline

Posts: 1715085713

View Profile Personal Message (Offline)

Ignore
1715085713
Reply with quote  #2

1715085713
Report to moderator
1715085713
Hero Member
*
Offline Offline

Posts: 1715085713

View Profile Personal Message (Offline)

Ignore
1715085713
Reply with quote  #2

1715085713
Report to moderator
"Governments are good at cutting off the heads of a centrally controlled networks like Napster, but pure P2P networks like Gnutella and Tor seem to be holding their own." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715085713
Hero Member
*
Offline Offline

Posts: 1715085713

View Profile Personal Message (Offline)

Ignore
1715085713
Reply with quote  #2

1715085713
Report to moderator
nomorecoin (OP)
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
May 07, 2013, 03:31:16 AM
Last edit: September 17, 2013, 09:27:25 PM by nomorecoin
 #2

TODO:
Add newer pairs
Verify key/secret pair are valid when starting commit
Test like crazy
Fix bug where bot doesn't place bids
Change min trade amounts. API limit appears to have changed since code was originally laid out. - bot currently trades full balance, issue is N/A
Implement a better simulation mode (low priority)
Improve exception handling (high priority)
Abstract the API portion to allow interchangeable exchanges
Add EMA signal type
Add stop loss

No Plans to Implement:
GUI
Compiled version
Cross-exchange arbitrage
MtGox anything

Known Issues:
KeyError printing existing orders, investigating. Set verbose = False to bypass this issue.
Graphing for some values is useless due to scientific notation on axes.

Potential Issues:
Bot is likely to be caught on the wrong side of a trend due to minimum volatility check
maverick1337
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
May 07, 2013, 05:37:06 AM
 #3

This may sound weird but is it possible to have a bot notify you (via email/text/etc) when the EMA lines cross, and that only? I don't want it to automatically trade but to just send me a notification of when they cross so I can initiate the trades myself. You wouldn't have to include any trading data or anything. I know people spend a lot o time and effort on their codes and was wondering if this was possible.

Thank you in advance for any help.
maverick1337
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
May 07, 2013, 05:42:50 AM
 #4

Thank you for the response. I have absolutely zero knowledge about python and trade bots in general. Would this work on a Mac or PC? I don't have linux.
maverick1337
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
May 07, 2013, 05:55:49 AM
 #5

Well I'm thinking of have it notify when M15/H1/H4 lines cross. That wouldn't be very emails at all. Also, would it be easy to implement Mt.Gox instead of BTC-e?
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 08, 2013, 07:41:22 PM
Last edit: May 08, 2013, 09:19:22 PM by billotronic
 #6

Silly question, does this bot only handle one pair at a time? ie, could I configure the ini to trade both btc_usd & ltc_usd? If no, can I run multiple instances to cover both items of interest? [edit] I can figure this part out myself

Thanks for this and thanks even more for the sim mode. I'm not much for trading much less trade bots so thats a nice feature for us n00bs to get a grip on the bot before turning it loose. Look forward to messing with this.

[edit 2] Another question, in the sim mode, it's pretty much just presenting information as opposed to showing theoretical trades that the bot would perform if simMode was set to False?

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 09, 2013, 12:12:05 AM
 #7

ooo, that is a really good point for which I did not think about. Maybe something for the future could be loading separate api's and separate settings per api? Assuming that's even desirable or feasible.

Quote
I'd like to improve the simulation mode to trade against a fake copy of your existing balance, adjusting it as it simulates trading.

Now that would be pretty neat. Personally, I think (if) bfl does indeed flood the market with ASICS we are going to see a surge of people looking into trading for coins (like myself) who would find much use and learning from a sim type tool (like myself).

Thank you for your work and I hope I can get to the point to send some fun to your grape juice fund for it! (gotta pay the mortgage first, boo!)

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 09, 2013, 02:00:42 AM
 #8

Toying with the sim right now. Is it a safe assumption that the values to set for the moving average is in days?

Python is definitely a wonderful language... I wish I knew more than just basic trouble shooting when I can't get an app to run on my linux boxes.

But now I have a problem. Running in as sim with tickers for btc_usd ltc_usd & ppc_btc with trade active for ppc_btc. I installed canopy with no errors. App has been running for about 10 minutes but nothing graphed. I am not familiar with canopy, is there anything I need to do with it?

I have python 2.7.3 and running Xubuntu 12.10.

Help? lol.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 09, 2013, 02:07:29 AM
Last edit: May 09, 2013, 02:30:59 AM by billotronic
 #9

I should also add that the file size of graph.png has increased, but damned if I see anything on it. Also tried increasing DPI to 800. Now I am trying changing the trade target to btc_usd to see if that makes a difference

[edit]hahahaha I should of known. Low and behold there just wasn't data to graph. Changed trade target and now I have a graph. Ignore previous silliness.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 09, 2013, 02:34:47 PM
 #10

Ok, after some tinkering I think I have found a bug. It appears that the bot does not like the existence of manually created trades. I'm running in sim with trading on btc_usd but I have open ppc orders which I think is the culprit.

Quote
Greetings, human. tAPI-bot loading...
tAPI-bot v0.51, starting.
Open Orders: 4
Traceback (most recent call last):
  File "Application.py", line 40, in <module>
    runLoop()
  File "Application.py", line 25, in runLoop
    printing.displayBalance()
  File "/home/x/Desktop/tAPIbot-master/tapi/helper.py", line 145, in displayBalance
    self.processOrders(printOutput=True)
  File "/home/x/Desktop/tAPIbot-master/tapi/helper.py", line 164, in processOrders
    order['pair'],
KeyError: 'pair'

I'm going to let my orders stand for a bit (come on bull!) and then try creating manual btc orders and see if that fixes the crash.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 09, 2013, 11:03:16 PM
Last edit: May 10, 2013, 01:59:33 AM by billotronic
 #11

Well that is what I thought too BUT took down my remaining orders for ppc and low and behold it has been running for 3 hours now with no crash whereas before it was crashing after start up. I think there is a bug there and I am all over trying to figure it out (started looking at the code watch out! [insert puking smiley from skype here])

I have the luxury of toying with this remotely on my server from work so if I get some proper time in the next few days I am going to run some experiments to see what I can see.

On a side note, you say that there is no error logging / debugging built it, what would it take to make that happen? Is there some sort of app or environment I could run this in that would give debugging info?

[edit] also, i know that python is cross platform and all, but maybe for posterity, we should list what os's we are running this on in case the finished product requires independent install instructions?

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
Jude Austin
Legendary
*
Offline Offline

Activity: 1140
Merit: 1000


The Real Jude Austin


View Profile WWW
May 11, 2013, 02:06:48 PM
 #12

In regards to the KeyError:

On line 143 of helper.py I changed:

Code:
if type(orders) == int and orders > 0: 

to

Code:
if type(orders) == str and orders > 0: 

And I no longer get that error.


Buy or sell $100 of Crypto and get $10!
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 11, 2013, 02:17:59 PM
 #13



In order to make a compiled, Windows-only exe (the only type I have any experience with), the way settings are stored and read would need to change. It's certainly possible though.

I was thinking more in the lines of dealing with the python dependencies. For example, if I type PyLab into my package manager I get a library named python-matplotlib that I might be able to use for charting in place of the HUGE install of Canopy. I don't know what your set up is, but my plan would be to load this onto one of my running pi's and the smaller install size would be ideal.

Otherwise, seems to be running nice and smooth. I've had it running for about 24 hours now in live mode with no crashes and the bot posting trades. I would have to say it seems to work pretty good with the little coin I am giving it to work with. I am looking forward to running this baby full throttle.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 11, 2013, 04:55:31 PM
 #14

Well I was thinking of setting up some VM's this weekend to toy around with fresh installs... the VM I am running your bot in is a bit messy to say the least. I will post if I find anything useful.

Oh and I should add that I would like to keep the graphing functional. My end goal would be a simple web based output screen for your bot that I can check up on and that would include the graph.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 11, 2013, 06:36:37 PM
 #15

with enough whiskey, i can do anything!

Had a thought. How hard would it be to keep track of profits? Let's say when the bot starts, it uses the balance info and the converts all balances to btc and then prints a total. Then you could have the bot print profit (or loss) against this total in btc when it prints balances? I figured btc would be the easiest base since almost all the pairs on btc-e are based on btc.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 11, 2013, 07:23:45 PM
 #16

Absolutely! The bot is already scraping the info from btc-e, you would just have to add a little more math to the bot.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
Jude Austin
Legendary
*
Offline Offline

Activity: 1140
Merit: 1000


The Real Jude Austin


View Profile WWW
May 12, 2013, 06:26:15 AM
 #17

It seems to me that the script get's out of whack.

At some point it starts doing the complete opposite, it will buy when high, then sell when low.

I will provide the log tomorrow for it.

It's crazy!

Anyway some BTC can change your schedule to make this script awesome?

Buy or sell $100 of Crypto and get $10!
Jude Austin
Legendary
*
Offline Offline

Activity: 1140
Merit: 1000


The Real Jude Austin


View Profile WWW
May 12, 2013, 02:03:25 PM
 #18

It seems to me that the script get's out of whack.

At some point it starts doing the complete opposite, it will buy when high, then sell when low.

I will provide the log tomorrow for it.

It's crazy!

Anyway some BTC can change your schedule to make this script awesome?

Trust me, I want it to be awesome. It is as awesome as my skills and time have allowed to date.

Did you change the MA line settings at all? Default is essentially random. Understanding how this thing trades (or decides to try to trade) might help you capture the volatility.

It looks at individual trades, so a 40 point MA line takes the last 40 trades. SMA plots a point from a simple average of these 40 points. VMA weights the trades by volume.
Single MA mode compares price to moving average. When the price is below the MA line, the market is seen as trending down. The opposite when the price line moves above the MA.
Dual compares 2 MA lines, one fast, and one slower.
Ribbon is an attempt at a better confirmation of a trend. 3 lines must agree before a trend is decided.

In any case, this bot is prone to errors, calling trends that never develop, lagging behind a micro-trend, etc. It has been profitable, but certainly not every day.

The key is setting it to capture the volatility.

Yes, a little better understanding would be nice.

So each of the values defined in settings.ini are N of last trades averaged, for the mode anyway?

So over time the best mode to use would be ribbon, correct?

I am a new and have a ton of questions and very little understanding of all this, lol.

Thanks for your time.

Buy or sell $100 of Crypto and get $10!
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 12, 2013, 06:17:04 PM
 #19

And it does not help much that the volume on BTC-E has been in the dumps for the past few days...

Jude, run it in sim mode till you have an understanding of the configuration settings is the best advice you can get. Set it for something with some movement and you will begin to see how the bot 'thinks' and reacts to market conditions.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 12, 2013, 06:18:18 PM
 #20

I would also add that I have turned off live trading right now due to everything on btc-e taking a dump!

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
Jude Austin
Legendary
*
Offline Offline

Activity: 1140
Merit: 1000


The Real Jude Austin


View Profile WWW
May 13, 2013, 08:48:57 AM
 #21

I don't mean to be a pain in the butt but I would really like to see the OrdersList.

Perhaps you could take a look at how this guy pulls that information:

https://github.com/alanmcintyre/btce-api/blob/master/btceapi/trade.py

If you look on line 203, perhaps that would help get this situation, well, situated, lol.

Thanks for everything!

Buy or sell $100 of Crypto and get $10!
miningusa
Member
**
Offline Offline

Activity: 98
Merit: 10



View Profile
May 13, 2013, 10:52:00 AM
 #22

There's a lot of bots floating around... any of them useful?
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
May 15, 2013, 11:25:29 AM
 #23

I get nearly the same output
Code:
ERROR Key error in helper.processOrders: 'pair'
it is now running in simulation mode; - can I see something in log.log how the balance has changed but for not running in simulation mode? (I don't find anything)
aparadox
Newbie
*
Offline Offline

Activity: 10
Merit: 0


View Profile
May 15, 2013, 06:28:32 PM
 #24

Thanks for the bot Nomorecoins

I'm glad I'm running it in sim mode until I find the some good settings because so far, regardless of my settings and with the low trading, I would be buying high and selling low.

I have an issue with the graph displaying some values. The graph itself shows up but not the lines when simulating ltc_btc trading. Any recommendation ?

I wish I knew how to code in Python to help you with this project. I guess I'll have to learn eventually Wink
yachtsman
Newbie
*
Offline Offline

Activity: 51
Merit: 0


View Profile
May 16, 2013, 04:43:30 PM
 #25

I have installed matplotlib into python27, now when i run applicatoin.py i get "no module named numpy"  I have also installed the Numpy from scipy.org

Im at a loss now...
yachtsman
Newbie
*
Offline Offline

Activity: 51
Merit: 0


View Profile
May 16, 2013, 06:43:27 PM
 #26

Never mind... i got it working now... pretty sweet bot if i say so.. i got it working through dos prompt..

Now time to tweak averages
aparadox
Newbie
*
Offline Offline

Activity: 10
Merit: 0


View Profile
May 16, 2013, 07:17:15 PM
 #27

Thanks for the bot Nomorecoins

I'm glad I'm running it in sim mode until I find the some good settings because so far, regardless of my settings and with the low trading, I would be buying high and selling low.

I have an issue with the graph displaying some values. The graph itself shows up but not the lines when simulating ltc_btc trading. Any recommendation ?

I wish I knew how to code in Python to help you with this project. I guess I'll have to learn eventually Wink

How long (how many ticks) has the bot been running for?
Can you post a (resized) image?

I'll put it on my list to check this out, I haven't run against ltc_btc in quite a while. Edit: I can confirm this issue, appears to be due to scientific notation on the axes labels.

Edit #2 seems to be due to rounding in setting the y-axis limits. Change the following in trader.py (near the bottom of the file) if you would like to test:

Code:
ymax = round(ymax+(ymax*0.001),5)
and
Code:
ymin = round(ymin-(ymin*0.001),5)

I don't want to commit until I ensure this won't wonkify other pairs' charts.

Thanks, that made it work. It was a rounding issue. It had been ticking for over 1000 ticks based on 30 seconds between each tick. Now I'll be able to visualise what happens.

The setting could be dynamicly adjusted according to the trading price range
f6gau
Newbie
*
Offline Offline

Activity: 13
Merit: 0


View Profile
May 16, 2013, 09:15:22 PM
 #28

hi,

i found your bot today and started it an hour ago.
the simulations seems to work either:
Code:
Simulated sell: btc_usd 108.119

my question (maybe silly):
how to see an overall win/loss?
Manually through the logs?

thanks Smiley


ps. if you need some testing data like logs etc. let me know
f6gau
Newbie
*
Offline Offline

Activity: 13
Merit: 0


View Profile
May 17, 2013, 03:10:18 PM
 #29

Code:
2013-05-17 08:22:26,976 WARNING Attempted order below 0.1: -1e-05
2013-05-17 08:22:26,976 INFO Attempted buy: btc_usd 109.101 -1e-05
2013-05-17 08:22:26,976 INFO Order failed

-1e-05 --> what is this?

and also where to configure the minimum order (0.1) the bot is always trying to trade less...

thanks
f6gau
Newbie
*
Offline Offline

Activity: 13
Merit: 0


View Profile
May 18, 2013, 11:14:59 AM
 #30

Code:
2013-05-17 08:22:26,976 WARNING Attempted order below 0.1: -1e-05
2013-05-17 08:22:26,976 INFO Attempted buy: btc_usd 109.101 -1e-05
2013-05-17 08:22:26,976 INFO Order failed

-1e-05 --> what is this?

and also where to configure the minimum order (0.1) the bot is always trying to trade less...

thanks

ok the issue with the minimum order is clear now ... trader.py
but i always get these "wrong" values like above.
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 18, 2013, 01:07:16 PM
 #31

What kind of finances are you giving the bot to play with?

I have not tried btc_usd but I have not had that error thrown with ltc_btc, ltc_usd, ppc_btc and had 10+ coins/$ in my accounts before starting the bot for testing.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
f6gau
Newbie
*
Offline Offline

Activity: 13
Merit: 0


View Profile
May 19, 2013, 08:23:29 PM
 #32

is it possible - for the bot - to remember the price btc was bought? i often see buy at 113.615$ and shortly after sell for 113.568$.
Mogumodz
Sr. Member
****
Offline Offline

Activity: 290
Merit: 250



View Profile
May 21, 2013, 12:57:47 PM
 #33

Just started it up in sim mode.

Had to install matplotlib and numpy to get it running.

Graph is updating nicely, Lets see what this can do.

Bitcoin OTC rating GPG ID: 3E7974A1 P2Pool statistics: p2pool.info
davider
Member
**
Offline Offline

Activity: 72
Merit: 10


View Profile WWW
May 21, 2013, 04:19:14 PM
 #34

Do you plan to implement also Exponential Moving Average as a signal type?
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
May 21, 2013, 06:57:36 PM
 #35

I try it now without sim mode with little money
Code:
/usr/lib/pymodules/python2.7/matplotlib/axes.py:2667: UserWarning: Attempting to set identical bottom==top results
in singular transformations; automatically expanding.
bottom=0.0, top=0.0
  + 'bottom=%s, top=%s') % (bottom, top))
what does this mean?
TIA
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 22, 2013, 03:05:16 AM
 #36

I have to baby sit it or else I come back to it buying high and selling low at times... that and I am a cheapskate even when it comes to testing.

Fees are an issue. Seems like the bot plays the margins too close for profitability most of the time, unless there is some good movement in the market. I have caught it making some good trades though and it seems that different trading pairs work better with different signals but I've set my sights on just ltc_usd for tweaking.

Another interesting realization I had the other day is no matter how good this bot might work, there are much meaner things lurking on btc-e... which is a fun catalyst by itself. The glory of the internet.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
Mogumodz
Sr. Member
****
Offline Offline

Activity: 290
Merit: 250



View Profile
May 22, 2013, 03:44:51 AM
 #37



I can see a few times when the streams look like they have predicted a few good trends (mostly late). This is just with standard settings on sim mode to see what it did over a few hours.

Going to somehow tally up all the buy an sell data and see what I would be left with. Left it running a long enough time I thought.

I wonder if the data could be exported to CSV or another format so a script or macro could tally up and down the values.

Bitcoin OTC rating GPG ID: 3E7974A1 P2Pool statistics: p2pool.info
nullbitspectre1848
Full Member
***
Offline Offline

Activity: 141
Merit: 100



View Profile
May 22, 2013, 02:37:05 PM
 #38

Is there a guide somewhere that defines the types of signals and what the values mean etc. (don't know how to adjust the signals if I don't know what the values mean)?  I'm rather new to these sorts of things, any help or starting point would be most appreciated.  Also, where does the graph output to?

billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 22, 2013, 02:43:47 PM
 #39

I have to baby sit it or else I come back to it buying high and selling low at times... that and I am a cheapskate even when it comes to testing.

Fees are an issue. Seems like the bot plays the margins too close for profitability most of the time, unless there is some good movement in the market. I have caught it making some good trades though and it seems that different trading pairs work better with different signals but I've set my sights on just ltc_usd for tweaking.

Another interesting realization I had the other day is no matter how good this bot might work, there are much meaner things lurking on btc-e... which is a fun catalyst by itself. The glory of the internet.

There is no magic bullet for all pairs, nor all days. You have to adapt your signal settings to make any profit. Volatility is your friend.

HA! You can say that again!

Still, I wish I kept better records of performance. I'm thinking it makes profit about 50-75% of the time which I do not think is bad since I'm not even a ranked amature when it comes to proper trading strategy... I just know how to read!

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 22, 2013, 08:47:28 PM
 #40

Is there a guide somewhere that defines the types of signals and what the values mean etc. (don't know how to adjust the signals if I don't know what the values mean)?  I'm rather new to these sorts of things, any help or starting point would be most appreciated.  Also, where does the graph output to?

Some quick internet searching on the moving average types and single types will give you a mind blowing amount of info.

Graph has to be enabled in the settings.ini and prerequisites met. Graph exports to ~/tapi/graph.png

Best advice, run it in sim mode until you feel comfortable with the settings.ini and the settings within.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 22, 2013, 08:50:18 PM
 #41


I'm thinking of ways to implement a minimum volatility trade "pause". When the trends are smaller than a round trip trade, we're guaranteed to lose. The bot could check the high/low gap over a certain range, and decide whether or not to try trading. Thoughts?

YES! That is exactly what I think is needed. Is it possible? This is pretty much what I do when I say baby sitting. If there is not enough action in my pair of interest, I just shut to bot down for a bit and wait. If this could be done automatically with variables, you might be on to something.

Further develop that thought... include multiple trade pairs and have the bought 'shop around' so to speak for the most volatility with the available currencies in your account?

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
sla73
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
May 23, 2013, 11:24:34 AM
 #42

Here's a quick run-down of my trading for today. I let the bot run against ltc_btc with a small amount.

Set ribbon, start 49, spacing 50, for MA lines at 49, 99, and 149.


Hi nomorecoin, I am enjoying playing around with this bot, many thanks for your hard work.. Once question how does the above setup, look in the settings.ini file?

Cheers..

P.S I get frequent crashes ...RuntimeError: dictionary changed size during iteration?
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
May 23, 2013, 02:16:00 PM
 #43

hi
Code:
# Enter single pair to trade and generate signals, eg: btc_usd 
pair = ltc_btc
is it only possible to run a single pair to trade or more at one time (if not, is it possible to run multiple instances with same API keys?)
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 23, 2013, 08:04:11 PM
 #44


Best advice, run it in sim mode until you feel comfortable with the settings.ini and the settings within.

This, for now. In testing, you want to configure the signals such that a "crossover" happens as near to peaks and troughs as possible.

It's unlikely that many will share successful setups in the future, but you can do some reading on crossover trading and moving averages. Be aware: conventional wisdom on these signals may not apply, or may be skewed, as the period used to calculate is individual trades, not days.

Oh boy you can say that again. I went into playing with this bot thinking I knew a thing about a thing or two but I sure the hell was dead wrong.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
sla73
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
May 24, 2013, 09:05:32 AM
Last edit: May 25, 2013, 09:28:35 AM by sla73
 #45


Hi nomorecoin, I am enjoying playing around with this bot, many thanks for your hard work.. Once question how does the above setup, look in the settings.ini file?

Cheers..

P.S I get frequent crashes ...RuntimeError: dictionary changed size during iteration?

Can you post the stack trace and relevant system info? That's a new one.

Sure here you go http://110.174.141.187/stacktrace.txt


Oh and running Win 7 64 bit (Prem) with Canopy.. 

Cheers sla73
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
May 24, 2013, 12:40:53 PM
 #46

Recommend separate accounts for anything sharing a base currency in the pairs traded. Multiple instances will not cause an issue, but each instance will attempt to sell/buy with all available currency it sees.
I have tried it with multiple instances (in different directories and different ini's), but:
Code:
Traceback (most recent call last):
  File "Application.py", line 40, in <module>
    runLoop()
  File "Application.py", line 23, in runLoop
    trader.update()
  File "/home/xxx/tAPIbot/tapi_TRC/trader.py", line 62, in update
    self.tradeData = self.tapi.update()
  File "/home/xxx/tAPIbot/tapi_TRC/api.py", line 24, in update
    self.tradeData['funds'] = output['funds']
TypeError: 'NoneType' object has no attribute '__getitem__'
seems no go..
sla73
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
May 27, 2013, 06:19:48 AM
 #47


Hi nomorecoin, I am enjoying playing around with this bot, many thanks for your hard work.. One question how does the above setup, look in the settings.ini file?

Cheers..

P.S I get frequent crashes ...RuntimeError: dictionary changed size during iteration?

Can you post the stack trace and relevant system info? That's a new one.

Sure here you go http://110.174.141.187/stacktrace.txt


Oh and running Win 7 64 bit (Prem) with Canopy.. 

Cheers sla73



Hi nomorcoin, am still having trouble trying to set up the [signals] section in settings.ini file for ribbon

could you please post an example?

cheers sla73
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 27, 2013, 12:23:12 PM
 #48

Trouble as in the bot is not making trades? Or the bot is making trades that are not making you money?


This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
sla73
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
May 27, 2013, 12:30:51 PM
 #49

Hi,
as in i can't figure out how to put the settings in the ini file.. where/ how do i put in the other 3 MA values?

if i want to Set ribbon, start 49, spacing 50, and the MA lines at 49, 99, and 149.

do i put them in

MAtype = 49, 99, and 149 <- like this or 49 99 149 ?


I have this set like below

# Ribbon:
# Note: ribbonStart + (3*ribbonSpacing) MUST BE < 150!
# This is because the platform only looks at last 150 trades (max returned by API)
ribbonStart = 49
ribbonSpacing = 50


thanks..
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 27, 2013, 12:37:32 PM
 #50

Code:
# Ribbon:
# Note: ribbonStart + (3*ribbonSpacing) MUST BE < 150!
# This is because the platform only looks at last 150 trades (max returned by API)
ribbonStart = 49
ribbonSpacing = 50

This is correct. Start is 49. Spacing is 50. 49 + 50 = 99. 99 + 50 = 149

This logic is here:

Code:
# Note: ribbonStart + (3*ribbonSpacing) MUST BE < 150!


Hope this helps.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
sla73
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
May 27, 2013, 12:39:36 PM
 #51

yep.. got it now many thanks.. doh! Roll Eyes
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 27, 2013, 12:51:08 PM
 #52

Good deal. Happy trading!

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
alexxy
Sr. Member
****
Offline Offline

Activity: 363
Merit: 250


View Profile
May 29, 2013, 08:52:52 AM
 #53

nomorecoin can you add trading fee in accounting? your bot works fine except that!

PS also why are you using your custom btceapi port? there is maintained version https://github.com/alanmcintyre/btce-api
nullbitspectre1848
Full Member
***
Offline Offline

Activity: 141
Merit: 100



View Profile
May 29, 2013, 10:53:39 AM
Last edit: May 29, 2013, 11:05:38 AM by nullbitspectre1848
 #54

So I've run this for a couple days with different settings, but I seem to pretty much get the same result.  It appears that I am buying low and selling high, but I am perpetually taking slow but gradual loss.  Is anyone actually making anything using this bot, or is everyone pretty much running into the same thing (as per previous messages in this thread)?
 

PS:  thanks for making this available to everyone Smiley

alexxy
Sr. Member
****
Offline Offline

Activity: 363
Merit: 250


View Profile
May 29, 2013, 12:44:04 PM
 #55

You get some loss because this bot doesnt take fee into account. So for example you're buy low and sell high but the difference is ~0.1% and trading fee is 0.2% so you get loss ~0.2% per iteration.
nullbitspectre1848
Full Member
***
Offline Offline

Activity: 141
Merit: 100



View Profile
May 29, 2013, 02:35:53 PM
 #56

You get some loss because this bot doesnt take fee into account. So for example you're buy low and sell high but the difference is ~0.1% and trading fee is 0.2% so you get loss ~0.2% per iteration.

Yes that seems to be what is happening.  Looks like it may read the trends/signals/MAs ok, but since it doesn't include a minimum trade threshold, loss is all you will get unless there are larger fluctuations.  I suppose one could insulate against that by making the refresh period much longer than 60 seconds, however, that would only really be a shot in the dark, hoping that over the cycle period a larger fluctuation has occured.

billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
May 29, 2013, 05:08:11 PM
 #57

So I've run this for a couple days with different settings, but I seem to pretty much get the same result.  It appears that I am buying low and selling high, but I am perpetually taking slow but gradual loss.  Is anyone actually making anything using this bot, or is everyone pretty much running into the same thing (as per previous messages in this thread)?
 

PS:  thanks for making this available to everyone Smiley

The fee's kill ya. Stagnant markets kill ya. This is not the easiest bot in the world to work with but has made me some bitchin trades... and then lost the profit through fee's on the following trades. I do not run this bot unattended. As quite as nomorecoin has been I would assume that he is messing with the code as we speak.

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
telemaco
Sr. Member
****
Offline Offline

Activity: 371
Merit: 250



View Profile
May 30, 2013, 08:33:35 AM
 #58

Hello,

Maybe you can add on settings.ini something like this:

Code:
ThresholdBuy = 0.02
ThresholdSell= 0.02

and on trader.py

Code:
        if signalType == 'dual':
            # lines cross each other = trade signal
            if self.signals.fastMA.value > self.signals.slowMA.value*(1+self.ThresBuy):
                print'Market trending up'
                self.log.info('Market trending up')
                #investigate
                #if self.shortPosition:
                self.placeBid()
            elif self.signals.fastMA.value*(1-self.ThresSell) < self.signals.slowMA.value:
                print'Market trending down'
                self.log.info('Market trending down')
                if not self.shortPosition:
                    self.placeAsk()

Cheers,

ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
June 10, 2013, 04:42:09 PM
 #59

Hello,

Maybe you can add on settings.ini something like this:
.
.
.
and what does this produce?
TIA
drwho88888
Member
**
Offline Offline

Activity: 70
Merit: 10


View Profile
June 12, 2013, 09:41:13 PM
 #60

Does EMA trading work profitably ? I think not. People have been trying to crack this in fx for years and I doubt anyone makes any money longterm. Obviously there are winners short term but really, if its was this easy we'd all be millionaires.
ironstove
Member
**
Offline Offline

Activity: 111
Merit: 10


Possibilities are limitless


View Profile
June 14, 2013, 05:01:49 AM
 #61

Hi, great that you've implemented a bot for BTC-e, I'll start helping with the testing/debugging... Looks like fun.
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
June 18, 2013, 03:58:22 PM
 #62

Hi nomorecoin
is it not possible to run multiple instances with multiple currencies?
I get always
Code:
Traceback (most recent call last):
  File "Application.py", line 40, in <module>
    runLoop()
  File "Application.py", line 23, in runLoop
    trader.update()
  File "/home/ewi/Downloads/tAPIbot/LTC_USD_tapi/trader.py", line 62, in update
    self.tradeData = self.tapi.update()
  File "/home/ewi/Downloads/tAPIbot/LTC_USD_tapi/api.py", line 24, in update
    self.tradeData['funds'] = output['funds']
TypeError: 'NoneType' object has no attribute '__getitem__'
or is there another problem the reason for this?
TIA
erk
Hero Member
*****
Offline Offline

Activity: 826
Merit: 500



View Profile
June 19, 2013, 12:11:48 AM
 #63

Can this bot be run in the command line in a text mode,  or does is require a GUI? eg. x11 on Ubuntu.

I am planning on using a headless Ubuntu server with no mouse, monitor, keyboard.

When I try and run it I get an error as if it want's X11

Code:
 File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1712, in __init__
    self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
June 19, 2013, 12:47:17 AM
 #64

Hi nomorecoin
is it not possible to run multiple instances with multiple currencies?
I get always
Code:
Traceback (most recent call last):
  File "Application.py", line 40, in <module>
    runLoop()
  File "Application.py", line 23, in runLoop
    trader.update()
  File "/home/ewi/Downloads/tAPIbot/LTC_USD_tapi/trader.py", line 62, in update
    self.tradeData = self.tapi.update()
  File "/home/ewi/Downloads/tAPIbot/LTC_USD_tapi/api.py", line 24, in update
    self.tradeData['funds'] = output['funds']
TypeError: 'NoneType' object has no attribute '__getitem__'
or is there another problem the reason for this?
TIA

It's mentioned some where in here that he recommends use a separate account per instance. This was cited as a precaution of over buying/selling a shared currency. The advice might also apply to your situation. It would be easy enough to test at least.

Can this bot be run in the command line in a text mode,  or does is require a GUI? eg. x11 on Ubuntu.

I am planning on using a headless Ubuntu server with no mouse, monitor, keyboard.

When I try and run it I get an error as if it want's X11

Code:
 File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1712, in __init__
    self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable

It does not look like it. Might be worth a pm to the author (have not seen him on this thread in a while)

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
sal002
Hero Member
*****
Offline Offline

Activity: 490
Merit: 500


View Profile WWW
July 07, 2013, 08:18:32 PM
 #65

Hello,

Maybe you can add on settings.ini something like this:

Code:
ThresholdBuy = 0.02
ThresholdSell= 0.02

and on trader.py

Code:
        if signalType == 'dual':
            # lines cross each other = trade signal
            if self.signals.fastMA.value > self.signals.slowMA.value*(1+self.ThresBuy):
                print'Market trending up'
                self.log.info('Market trending up')
                #investigate
                #if self.shortPosition:
                self.placeBid()
            elif self.signals.fastMA.value*(1-self.ThresSell) < self.signals.slowMA.value:
                print'Market trending down'
                self.log.info('Market trending down')
                if not self.shortPosition:
                    self.placeAsk()

Cheers,



There is a fee setting in the ini - maybe someone could come up with some code to implement it?
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
July 09, 2013, 11:54:23 AM
 #66

feedback:
now I have run the bot for ~2 weeks with the default options
start was with
USD:  0.00
BTC:  1.00
now after xxx trades result is:

Code:
Available Balances:
USD: 0.02570973
BTC: 0.96450296
means, that there has to be some options to change
but which?
 Wink
syphen
Member
**
Offline Offline

Activity: 102
Merit: 10


View Profile
July 29, 2013, 05:49:53 AM
 #67

I keep getting error parsing trades error when I run application.py
piotars_kbw
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
July 29, 2013, 09:10:37 PM
Last edit: July 30, 2013, 07:21:34 AM by piotars_kbw
 #68

Since yesterday, I have the same problem. It just stop working: (
The configuration has not been changed, the software also unchanged.


EDIT:

Already running, it looks like it's a problem with btc-e api.
daybyter
Legendary
*
Offline Offline

Activity: 965
Merit: 1000


View Profile
September 11, 2013, 11:56:52 AM
 #69


No promises, but I'll try to set aside some time to make a few changes.

Edit: if you got the generic "Error parsing trades", that is likely the API failing to respond. I didn't/don't have great exception handling going on.

Check the HTTP response code. It's most likely 504 with some HTML from cloudflare, or so...

ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
September 11, 2013, 02:47:54 PM
 #70

Code:
Traceback (most recent call last):
  File "Application.py", line 57, in <module>
    runLoop()
  File "Application.py", line 33, in runLoop
    trader.update()
  File "/home/xxx/xx/trader.py", line 113, in update
    self.evalOrder()
  File "/home/xxx/xx/trader.py", line 177, in evalOrder
    self.placeAsk()
  File "/home/xxx/xx/
line 256, in placeAsk
    order = self.placeOrder('sell',rate,amount)
NameError: global name 'amount' is not defined
ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
September 13, 2013, 10:40:21 AM
 #71

thx
but now I get always
Code:
Order returned error:/n You incorrectly entered one of fields.
which field?
jago25_98
Hero Member
*****
Offline Offline

Activity: 900
Merit: 1000


Crypto Geek


View Profile WWW
September 13, 2013, 01:37:06 PM
 #72

Am I right in thinking that EMA is the only (reliable) bot method for btc?

Bitcoiner since the early days. Crypto YouTube Channel: Trading Nomads | Analyst | News Reporter | Bitcoin Hodler | Support Freedom of Speech!
daybyter
Legendary
*
Offline Offline

Activity: 965
Merit: 1000


View Profile
September 13, 2013, 04:57:48 PM
 #73

Arb is better methinks?

ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
September 16, 2013, 08:07:04 PM
 #74

Edit: if you'd like to do some testing, uncomment either or both of the following from tapi/trader.py:

Code:
         
#amount = round((balance/rate),3)
Code:
    
#amount = amount - 0.00001


I have uncommented both an get the same again
Code:
Volatility is 1.86%
Market trending up
Order returned error:/n You incorrectly entered one of fields.
Signal Spread: 0.73%
MCT
Newbie
*
Offline Offline

Activity: 6
Merit: 0


View Profile
September 26, 2013, 05:13:51 PM
 #75

Nice piece of code BUT you really have to fetch candles via bitcoincharts api. The last 150 trades are just a too small timeframe to build MAs on. I tried several options but only loosing money due to wrong signals.

Please consider at least to download the last ~100 hours of tradedata from the bitcoincharts api and calculate hourly close prices.

Then we could use crossing averages strategies on those pseudocandles.


ewibit
Legendary
*
Offline Offline

Activity: 2955
Merit: 1049


View Profile
September 26, 2013, 05:41:42 PM
 #76

I tried several options but only loosing money due to wrong signals.
for me the same..
billotronic
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


Crackpot Idealist


View Profile
September 27, 2013, 04:19:35 PM
 #77

Nice piece of code BUT you really have to fetch candles via bitcoincharts api. The last 150 trades are just a too small timeframe to build MAs on. I tried several options but only loosing money due to wrong signals.

Please consider at least to download the last ~100 hours of tradedata from the bitcoincharts api and calculate hourly close prices.

Then we could use crossing averages strategies on those pseudocandles.


The program is open source. Feel free to make changes. I've long wanted to properly abstract the API portion, but haven't found the time to do so. I will add this to my possible todo list though.


Nice to see you working on this again bud!

This post sums up why all this bullshit is a scam
Read It. Hate It. Change the facts that it represents.
https://bitcointalk.org/index.php?topic=1606638.msg16139644#msg16139644
MCT
Newbie
*
Offline Offline

Activity: 6
Merit: 0


View Profile
October 02, 2013, 10:48:31 AM
Last edit: October 02, 2013, 12:57:00 PM by MCT
 #78

Anyone else has problems with placing orders on btc_usd?

Sometimes it just does nothing when it says market trending up and sometimes it says not enough usd.
dna2
Newbie
*
Offline Offline

Activity: 33
Merit: 0


View Profile
October 11, 2013, 09:34:49 PM
 #79

If anyone is testing this with PPC_BTC, add the following in trader.py:

def getPip(self):
        '''provides correct minimum pip for orders, BTC-e specific'''
        pair = self.config.pair
        if 'ltc' in pair or 'nmc' in pair or 'ppc' in pair:
            return 0.00001
        else:
            return 0.001
ravagetheearth
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
October 19, 2013, 04:12:51 AM
 #80

Edited thread title to inactive. Other projects have been consuming my time.

That saddens me   Embarrassed

Good luck with your other projects though  Wink
ravagetheearth
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
October 20, 2013, 06:35:25 AM
 #81

Edited thread title to inactive. Other projects have been consuming my time.

That saddens me   Embarrassed

Good luck with your other projects though  Wink

Thank you. I won't say the project is dead, I may revisit when I have the time to test and tune.

That would be great!! I'm currently learning python just so I can tweak this. Thanks for the code Smiley Looks like you put a decent amount of time into this!
ravagetheearth
Newbie
*
Offline Offline

Activity: 27
Merit: 0


View Profile
October 22, 2013, 02:35:12 PM
 #82

Edited thread title to inactive. Other projects have been consuming my time.

That saddens me   Embarrassed

Good luck with your other projects though  Wink

Thank you. I won't say the project is dead, I may revisit when I have the time to test and tune.

That would be great!! I'm currently learning python just so I can tweak this. Thanks for the code Smiley Looks like you put a decent amount of time into this!

A lot of time... I wrote this as a way of writing functional code I was interested in while learning Python basics myself.

A word of warning; most of the code is extremely amateur, and does not follow best practices. Frankly, it's a mess. There are many areas for improvement.

Best of luck! As others have stated, the biggest area of functional improvement is a better source of ticker data.

Thanks for the tip! I'm a first year networking student and have almost no experience with coding. I am basically learning from the ground up. Someone I know who trades 100's of BTC used this bot as a shell for the one that he wrote and he recommended this one to me. I can't even get this to run  Roll Eyes I'll get a hang of it though. I hope you don't mind if I message you every once in a while to ask you a question about it Smiley
DobZombie
Hero Member
*****
Offline Offline

Activity: 896
Merit: 532


Former curator of The Bitcoin Museum


View Profile
October 25, 2013, 01:39:51 PM
 #83

I'm getting this A LOT.  I think it only happens when it attempts to make a buy. bot was working pretty good until this started happening...

Code:
Volatility is 0.84%
Market trending up
Traceback (most recent call last):
  File "application.py", line 57, in <module>
    runLoop()
  File "application.py", line 33, in runLoop
    trader.update()
  File "C:\tAPIbot-master\tapi\trader.py", line 113, in update
    self.evalOrder()
  File "C:\tAPIbot-master\tapi\trader.py", line 172, in evalOrder
    self.placeBid()
  File "C:\tAPIbot-master\tapi\trader.py", line 216, in placeBid
    amount = balance/rate
TypeError: unsupported operand type(s) for /: 'float' and 'NoneType'

Tip Me if believe BTC1 will hit $1 Million by 2030
1DobZomBiE2gngvy6zDFKY5b76yvDbqRra
DobZombie
Hero Member
*****
Offline Offline

Activity: 896
Merit: 532


Former curator of The Bitcoin Museum


View Profile
October 26, 2013, 12:58:03 PM
 #84

I've figured out it's directly related to changing...
Code:
min_volatility = 1.0
# Min volatility sleep: time in seconds to sleep between min volatility checks when volatility is below threshold
volatility_sleep = 120
to
Code:
min_volatility = 0.8
# Min volatility sleep: time in seconds to sleep between min volatility checks when volatility is below threshold
volatility_sleep = 90

Is it possible that increasing the amount of times that the api is checked can induce an response that confounds the bot?

Tip Me if believe BTC1 will hit $1 Million by 2030
1DobZomBiE2gngvy6zDFKY5b76yvDbqRra
xhabit
Full Member
***
Offline Offline

Activity: 209
Merit: 100



View Profile
November 03, 2013, 10:51:19 AM
 #85

I'like this bot really!!!! I'hope you will find time to tune the bot ... for giving profit ...

Bitcoin Priester German BTC PoolParty League
DOGE: DQz6dAAGZ3jyWhhnBvfey73VX5jeZ26e2N
Pages: 1 2 3 4 5 [All]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!