4 ms·
+1. My stream of thought is "it's some game and I guess trading is involved? Is this some sort of old school BBS game? Fuck, I have no clue.."
by aantix 10y ago
+1. My stream of thought is "it's some game and I guess trading is involved? Is this some sort of old school BBS game? Fuck, I have no clue.."
- disgruntledphd2 10y agoStep 1: read the API docs. Step 2: write an API client Step 3: Connect to a level Step 4: Lose loads of money Step 5: ??? Step 6: Profit! Note: I have not actually achieved step 6, but I blame a detour into learning C++ and wrapping a websocket client in R.
- kbenson 10y ago> I have not actually achieved step 6, but I blame a detour into learning C++ and wrapping a websocket client in R. I always assumed detours like that (assuming you are referring to doing/starting that because of the game) would be one of the most useful benefits to playing. It forces you to have to explore areas that you might not normally get into based on your job and interests.
- disgruntledphd2 10y agoCompletely, its been a lot of fun, and I surprised myself by enjoying reading the RFC (full disclosure, I always liked doing that). That's what I'm taking it as a license to do. I mostly do statistics/analysis for a living, so building automated systems is pretty new (and fun) for me.
- thmcmahon 10y agoHow'd you go with wrapping the websocket client in R? I've been putting together an R client and am stuck on how to do the websocket given the lack of R websocket libraries.
- Bootvis 10y agoI think your best bet is wrapping an existing C++ library using RCpp[1] that will require some work but I hope not too much. [1] I would have really liked that as I ended up writing all data to SQLite and then imported it to R for analysis. Not the most elegant solution...
- disgruntledphd2 10y agoThat is exactly what I am (currently) doing. Its actually a little tricky because of the stream-like nature of websockets. Currently I'm just writing to a file, but ideally I'd like to use the R connection API. The issue with that is that there doesn't appear to be a Rcpp wrapper around that particular API so I may have to do that (or test my theories by just using scan to read from the file after using a c++ binary to write it (using system). Its a dirty hack, but appears to work. FWIW, websocketpp is the C++ library I'm using.
- nialo 10y agoMaybe not the most elegant solution, but it could be worse: I wrote all the data to a csv file and then imported into Excel for analysis.
- dragonwriter 10y agoMy explanation, having done some of the levels: You know the myriad of websites with programming challenges and some kind of automatic assessment of how well you complete them? Well, its like one of those, but the challenges, rather than simple things like "write a Ruby program that consumes a series of lines on stdin with numbers and spits out a series of lines on stdout with the prime factorization of the corresponding input line" are things like "write a bot to interact with our stock trading HTTP and WebSocket APIs, that will make a specified amount of profit trading this particular stock within these particular constraints".