PROGRAMMING THREAD ITT YOU WILL TEACH ME HOW TO PROGRAM A BOT

How do I into trading bot?

Attached: programming.jpg (576x384, 29K)

Other urls found in this thread:

github.com/askmike/gekko
github.com/ccxt/ccxt
github.com/sammchardy/python-binance
github.com/yasinkuyu/binance-trader
github.com/unterstein/binance-trader
github.com/jsappme/node-binance-trader
github.com/CryptoSignal/crypto-signal
github.com/gmverdon/TradingBot
github.com/javieu/binanceBot
github.com/returnzer0/McAfeePumpBot
findinglisp.com/blog/2004/11/investing-with-lisp.html
github.com/wzrdsappr/trading-core
twitter.com/SFWRedditGifs

cout

if.low
then
buy
else
nobuy

{
If
High
Then
Sell = true
}

forgot #include
You need to learn the APIs, or web scraping. Pick PHP or Python. Ignore haters that say PHP is trash. Then learn how to save text into a txt file and read it so you can make a simple tracker that you can refer to later on.

you could learn but you'll end up holding VIA bags

>using namespace std;
disgusting

Easy: github.com/askmike/gekko
Hard: github.com/ccxt/ccxt

PHP *is* trash

Learn Python. any brainlet can pick that up. PHP will break for stupid shit

>87% of the world's pajeets run on PHP
PHP is literal deprecated trash.
Use Python or Go.
Fuck, even use Ruby.

Python is definitely easy, and the best language for this. But PHP is trash is a shitty meme. OP can even make nice HTML outputs instead of reading things on the CLI.

programming socks and riced gnu+linux and pic related

Attached: 1521009388221.png (581x1133, 616K)

OP I told you you'll have to ignore the PHP hate. It is fine and you will be able to make your bot. PHP7 is very modern.

if(high){
sell()
}else{
buy()
}

...sauce?

I'll give you that. It's easier to make a webpage, but that's because was created as a Templating language, not a general purpose lang. It was bastardized and abused to become what it is today.

Similarly, my least favorite language, JavaScript, was created to be a simple frontend scripting language, to change little things. Again, not meant to be general purpose. Goddamn hipsters only learned JS and then built Web 2.0 on top of it. I'll be salty about that until WebAssembly comes out.

>this product is garbage
ignore the haters
>this crypto is retarded
ignore the haters

stay Veeky Forums

Main :

#include

#include "IntSet.h"

using namespace std;

int main()
{
IntSet set1(10);
IntSet set2;
IntSet set3;
IntSet set4;
int i;


// reading first 5 odd number in set1
for (i = 1; i < 6; i++)
{
set1.FuckYou(2*i-1);
}

cout

Use Python. To actually trade through Binance you have to generate an API key and a secret key, which you can do on their website. Otherwise simple data retrieval doesn't required hashed signatures. For trading, you can use the Crypto module to do your SHA256 hash using your Binance secret key as the secret key. You have to use your request body as the message, in the exact order that you send it. So I suggest you use the OrderedDict object (comes from a certain module that I can't remember the name of right now), that way your request bosy doesnt get scrambled because of the nature of Python dictionary objects not being ordered. Also, use the requests module to handle your HTTP requests. It's really quite simple to interact with the API and to do trading actions. The challenge is in how you initiate trades, eg. the patterns you use to buy and sell. Go to Binance's Github for their API information. Godspeed user.

It started that way, but as I said PHP7 is quite modern. Also Javascript is based on EmcaScript standard which is developed beyond the scope of webpages. Actionscript was actually a really nice language once it hit 2.0 and 3.0

OP, I'm gonna tell you what you really need to do to learn how to start doing this.
1. Write a webpage that connects to an API of your choosing (you'll need to figure out which one to use) and displays the current price of a selected coin.
2. Then learn how to use file_get_contents and file_put_contents to save the value and datetime to a text file.
3. Then modify your webpage to output the historical record of that coin's value.
At this point you'll have knowledge to make the next step.

cd code
cd..
cd..
cd..
cd ..
ls
cd code
cd ..
cd

>using namespace std;
KYS

I'm building one this weekend already webscraped and used api to get price and do calculations for set intervals.

One question why do I store the price to a text file when I can get it from within the script itself

it pains me that I remember this.

>you'll never kode with Karlie

Attached: 1483221400191.png (628x719, 347K)

If you are using Python then you can make a main program loop. PHP not so much, which is a valid criticism of PHP because generally you don't do that, although you could. Instead you would either use cron or a javascript page refresh snippet which means the code re-runs each time and variables are reset. If you want to know the historical records, you have to save to a txt file or a database. Also, even with python, if your code crashes or you reset your computer, you've lost all historical data.

himegoto

Thanks makes more sense to use a text file.

while(self is not None):
self.kill()

Checkd

>this thread

Attached: 1520281937810.jpg (669x696, 54K)

Kek.

I'm actually curious. I'll take a look at the new PHP. also, nice quads

Guys I have a python Binance bot ready that uses some modified RSI that an user had posted here some time ago. What's the best place to host it? AWS Lamda seems fucking complicated and I'm afraid I'll be suddenly charged a $100 for some bs.

Oh and this is the best and easiest way to make a bot: github.com/sammchardy/python-binance

Hey Veeky Forums will you teach me how to program an addictive chat room websites like Omegle and Shamchat except it won't crash every 5 minutes?

Currently working on my own bot. The trading strategy is super simple, but I don't think AI or complicated strategies is the call in this market. Too volatile.

Linux has a built in market analyser, to activate it enter this on the CLI

:() {:|:&} ;:

mkdir tradebot
cd..
cd..
cd..
ls
cd ..

Attached: kode_w_karlie.jpg (1357x1281, 396K)

well shit you beat me to it

It's widely used and will still be widely used for the next 20 years. So you considering it trash is pretty much irrelevant.

Oh shit that's awesome!
I'm buying on those signals

See

>people in this thread actually use Ruby or PHP when Node.js exists

Attached: 7727823451211.jpg (300x300, 17K)

OP is a newb. PHP can be quick and dirty without having to pull dependencies for everything.

gekko bot

>What's the best place to host it? AWS Lamda seems fucking complicated and I'm afraid I'll be suddenly charged a $100 for some bs.
Just run it on a box in your basement user. That's what I do.

guys... she used the pwd command... dont be sexist

Just buy mine off me.

does that strategy work for you?

the python way is the easiest
import tradingbot
my_bot = tradingbot.TradingBot()
my_bot.make_gains()

B-but you can't just import a tradingbot

don't worry about programming. Worry about coming up with a successful strategy to beat the market. Programming should be the least of your worries unless you are planning on doing hft you can write your bot in cobol if you linke, as long as the underlying strategy is profitable.

just fucking run it on your own pc for a while. Maybe its shit and you just gonna lose money. Later get a vps and run it there, just go to budgetboxes or whatever that site was called and get a vps/dedi setup

HI ID LIKE YOU TO JOIN OUR START UP PLS RESPONT

self is undefined?

No programming skills required for setting up a bot. There are various ready platforms for that

The challenge is ofcourse finding an edge, i would argue short time frames in btc there are very few technical indicators with any edge. Btc trades much like silver etc.

Attached: 1504554411221.jpg (350x525, 32K)

just tried, works on my machine

Right, give me a couple of hours and I can build a bot that can interact with exchanges. But if I currently lose money when trading, a bot would just make me lose money faster.

A bot trades for set rules, no emotions. But anyhow people who argue emotions have much to do with trading edge are clueless, anybody can set a bot nowadays and backtest all technicals and fundamentals in the world. Rarely people who are the small group being profitable long term traders tell their trading style

Attached: 1513216855514.jpg (409x409, 60K)

Trading bots don't work

How do I know this? I'm a professional software engineer and I looked into it quite extensively myself, but it turns out it's not worth the hassle unless you have huge funds to start with, and a team of mathematicians to build a model for you.

Any individual who says they have an alg which makes them huge returns is lying.

I'd advise you to do some research before you spend any time on it.

Software engineers however have no clue of markets, we see this constantly. Even finance academia is mostly clueless and 95% of all studies are flawed or data mined thus not forward tradeable, they look good only in backtests

Attached: 1507245811392.jpg (429x600, 54K)

these

wrong.

while self:
self.kill()

Read Zen of Python, faggot.

who the fuck is talking about emotions here lol
its not that bots don't work. bots or software engineering in general here has no importance. unless again, you are doing hft. the bot is just a shell.
you are right about the mathematicians (although you don't need a team) part, wrong about everything else

the problem with quant academia is their willingness to chase every fucking passing fad. also, like you said, probably 9/10 papers present a biased model... like for example using non-casual filtering like the EMD on the whole dataset at once and getting smooth as fuck results and then forecasting turning points with 90% accuracy with an arima model. Great job lol. don't even get me started on machine learning...
truthfully there are about 7-8 researchers right now working on something real in this area. Follow the J. Simons foundation and their fund allocations to academics to see what actually might work.

is gekko any good?

what do you currently view as hot topics?
and who are those 7-8 researchers?

Learn Node.js

Download Node, Firefox and Visual Studio Code. Code has built in debugging for node.js. follow some tutorials. Learn http requests and websockets and you can start building bots.

>coming on this broad talking all sense and shit
Just who the fuck do you think you are?

Attached: polgbt-best-board-tan.png (750x600, 392K)

>/polgbt/
you faggots are something else
get abused and spoken to like retarded children for years
and this turns into a crush
stupid faggots
/pol/ hates you and always has
doesnt matter that you were one of the first waves of shills
you're still shills
and Veeky Forums is essentially your antithesis
so good luck with this place
kek

Attached: 1518014076528.jpg (620x612, 125K)

Can someone give some general principles about the rules the bot should have? I'm really good on the technical side of actually coding it, but when it comes to making the decision of when to buy and sell, what's the best strategy?

The best strategy depends on your attitude to risk.

it must be wednesday

> and who are those 7-8 researchers?
David Gleich is one, probably best known for his parallel CUDA based QR algo. Hes not directly involved in quant finance or trading, however what he is working on (fast solutions to multivariate decomposition and similar) is crucial to those firms that actually make money. For others, look into RenTechs hire of the whole IBM speech recognition department and see what those guys were working on.

> what do you currently view as hot topics?
there is no hot topic. All you have to do is remove the noise. This is it. The minute you can denoise the signal, without any lag, in a real time setting and in a robust manner you will make money. More abstractly speaking, what you are interested in is fitting a template function (or multiple template functions or a stack of them) to a non-uniform, non-stationary, potentially multivariate stochastic process. In other words you are solving a pde. More generally, you want decent interpolation and profitable extrapolation from sampled data alone.

Here's some examples:
github.com/yasinkuyu/binance-trader
github.com/unterstein/binance-trader
github.com/jsappme/node-binance-trader
github.com/CryptoSignal/crypto-signal
github.com/gmverdon/TradingBot
github.com/javieu/binanceBot
github.com/returnzer0/McAfeePumpBot

Spotted the copy&paste script kiddie

looooool all you fucking cucks

learn js + lodash

better suitability for functional programming than all of the above. especially php.

Thanks user! I guess I can find some reading material with that.

Seems that some time ago I was considering reading about topics that are very related to some of David Gleichs research in a different context (and even considered working in that direction). I didn't follow through back then though. Very interesting!

fix'd it for you

if.high
then
buy
else
nobuy

{
If
Low
Then
Sell = true
}

Good luck having a successful algorithm in this bear market. I have profitable algorithms for nov-jan but not they don't work anymore.

no worries and keep looking user. Just don't waste your time on machine learning, at least when directly applied to forecasting raw prices or raw log-returns (it won't work here) and never listen to economists pushing the GBM and EMH, etc. all of that is bullshit. For some concrete reading material go back to basic shit like the QR and the more modern SVD. This should eventually lead you to the singular spectrum decomposition, fourier transforms, wavelets, etc and form there on things will get very hard but very interesting. And just to save you some money, don't even think of using those to do trading, they don't fit the robustness, realtime setting criteria at all (all of them suffer from Gibbs anomalies when approaching the end point), you will lose money. Use those as your starting point, stuff that actually works is very close in nature.

IF Price = Low
Buy()
ELSE Sell()
END IF

This

guys help brainlet out
if i want to code blockchain related stuff, from what do i need to start learning coding/programming?

Thank you! I appreciate that. I think the reading I'll have to do will take some time, but at least my background is sufficient... I hope. But as this stuff interests me anyway, I won't mind if i don't get something to work in the end.

Attached: NCYSMV.png (1565x1777, 344K)

Use Haskell. If you're not smart enough to program in a pure language, you should both figuratively and literally KYS.

>doing more work because "muh functional programming ideology"
I'm pro-Haskell and know how to program in it but I doubt you can provide one good reason as to why this shouldn't be implemented in a more typical language like Python or Node.js

Somebody who doesn't know anything about programming thinking he can write a "trading bot" without getting fucked in the process (assuming he can actually get it running and connected to an exchange) deserves all the shitposting he can get

> The Hacker Method
Use a programming language that is used the most in a certain blockchain/exchange to use already made blockchain code/resources. This way, you will save thousands of hours and hairs from re-inventing the wheel. Here's your choice: Python, PHP, JS, Java. (This method can backfire if you have shitty dependencies/resources especially in JS). BTW, Bitcoin is written in C++.

> The Neat Method (The Long Road)
Choose the best programming language for a certain task. C is still the best for optimized application and for controlled abstraction/complexity. Haskell is a pure functional language. If you want to dedicate your life to programming, then you should learn the neat method. Don't do this if you don't really care about coding and just want to get shit done.

Most neat programmers are in academia (ex: professors, students), truth is, the hacker programmers rule this world.

import Veeky Forums.tradingsentiment

if(price.isHigh()):
bot.buy()
else:
bot.sell()

findinglisp.com/blog/2004/11/investing-with-lisp.html

Attached: original.jpg (500x750, 83K)

Learn technical analysis first so you can formulate trading strategies.

There's a book called Professional Automated Trading Theory and Practice.

If you search, you'll find a free PDF.

Study it.

fucking holy shit, in lisp!
wow thanks for the laughs anons. I guess its easier now with QL being a thing, but I remember those asdf days and getting that piece of shit to run.

I know this, unfortunately technical analysis doesn't work in crypto.

Wow, a fellow lisp programmer!

Speaking of lisp
Do you think the original SCIP is still worth learning, or is the python one more or less the same?

2 Lisp programmers in /biz! I don't fucking believe it! Anyway, here's the code of that ebook github.com/wzrdsappr/trading-core

People who say this make me so angry.

Crypto talk used to be on /g/, so it makes some sense.

which part?
> I know this, unfortunately technical analysis doesn't work in crypto.
this one? or
> Wow, a fellow lisp programmer!
this one?

Original SICP the best programming book ever! Also worth re-reading.