Programming Language for advanced Automation

Post Reply
User avatar
HRacing
Posts: 278
Joined: Tue May 14, 2013 11:25 am

Hi All,

Just thought I would ask forum users what their preferred programming language is for advanced automation. I have seen Peterle mention he uses C# for some of his automation but just was wondering what people would suggest for a complete newbie in the coding world.

Regards
User avatar
jimibt
Posts: 3641
Joined: Mon Nov 30, 2015 6:42 pm
Location: Narnia

I also use c#. I don't know if I could really say that it's the BEST language for automation. It is however the language that I use daily and am most familiar with. There are quite a few libraries on github that give a good starting point with the api-ng (and there's also a fairly recent example using the streaming api). I also know that linusp has put up a very nice starting point (in fact, way more than a starting point) using python, so this also may be worth looking at.

At the end of the day, there will be no BEST language but you will find a language that suits you best and that's probably as good a starting point as any.
User avatar
HRacing
Posts: 278
Joined: Tue May 14, 2013 11:25 am

Thankyou for the quick reply jimbit. I suppose I was asking the question to get a feel on what most people use as I will be diving in head first with absolutely no expereince of coding whatsoever so it will be a long time before I have any sort of automation running on my own. Just thought it may be worth investing time with it especially if im going down the automation route more than manual trading.
Last edited by HRacing on Tue May 30, 2017 12:29 pm, edited 1 time in total.
User avatar
Euler
Posts: 24701
Joined: Wed Nov 10, 2010 1:39 pm
Location: Bet Angel HQ

Linus has posted some python libraries in the Betfair API section
User avatar
jimibt
Posts: 3641
Joined: Mon Nov 30, 2015 6:42 pm
Location: Narnia

I'd suggest that a few fairly important things to consider in your choice of language may be:
  • accessibility of the language in terms of you being comfortable with it's syntax and conventions
  • level of tooling and support
  • width of 3rd party tools and libraries available for your particular use-case
  • support from the community here with suggestions/issues
  • your self commitment to progress beyond the basics when the learning curve demands
the above is not an exhaustive list and may be things that you have already considered. I think a few other replies will form the basis of both your generic and specific thinking on this.
User avatar
Frogmella
Posts: 220
Joined: Mon May 30, 2011 2:44 pm
Location: Towcester

To start with, can I suggest that you link Excel to BA and do your programming behind Excel using VBA (Visual Basic for Applications). Its much easier to learn than any of the .net languages and doesn't come with the unnecessary OOP (object oriented programming) baggage. Also, you don't then have to learn the Betfair API-ng, (and Betfair charge £300? for you to use live data via the API), you don't have to learn to use a JSON parser, you can get started quicker and It will give you a stepping stone before proceeding on to the pro-stuff.

Believe me, getting to grips with .net is a monumental pain the the backside if you just want to program some quick stuff for your own use.
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

Frogmella wrote:
Tue May 30, 2017 1:46 pm
To start with, can I suggest that you link Excel to BA and do your programming behind Excel using VBA (Visual Basic for Applications). Its much easier to learn than any of the .net languages and doesn't come with the unnecessary OOP (object oriented programming) baggage. Also, you don't then have to learn the Betfair API-ng, (and Betfair charge £300? for you to use live data via the API), you don't have to learn to use a JSON parser, you can get started quicker and It will give you a stepping stone before proceeding on to the pro-stuff.

Believe me, getting to grips with .net is a monumental pain the the backside if you just want to program some quick stuff for your own use.
+1

VBA is certainly the most accessible language for a complete beginner. The only problem there's ever been with BASIC is the stigma attached to it's name, people wouldn't knock it so much if it had a sexier name.
User avatar
HRacing
Posts: 278
Joined: Tue May 14, 2013 11:25 am

Thanks for your thoughts, VBA has been more than helpful in a few projects for me but just wondered what the 'pro's' were using as there way of automation.
PeterLe
Posts: 3715
Joined: Wed Apr 15, 2009 3:19 pm

HRacing wrote:
Tue May 30, 2017 11:58 am
Hi All,

Just thought I would ask forum users what their preferred programming language is for advanced automation. I have seen Peterle mention he uses C# for some of his automation but just was wondering what people would suggest for a complete newbie in the coding world.

Regards
Yes Im running one of my programs right now!
C# was new to me, and I enrolled on a course by UDEMY (google it)...superb learning tool
Unless you have a lot of time to spare learning it from scratch, you may want to get someone to build a program for you and then just have the ability to edit the code yourself
Regards
Peter
LinusP
Posts: 1871
Joined: Mon Jul 02, 2012 10:45 pm

I learnt python on codeacademy, then jumped straight into using the API, haven't looked back since!

I would say python is one of the most popular languages for using betfair due to its simplicity and the huge amount of libraries available. Best is a function of what you are looking for as it's not the quickest language.
User avatar
HRacing
Posts: 278
Joined: Tue May 14, 2013 11:25 am

Cheers PeterLe, Iv always wanted to learn a programming language even if not to use with betfair but purely for the fact that it interests me :). How this is then implemented into a auto stratergy im not sure but I will be on the look out for a programmer to test the water for sure. Just seen your post pop up Linus. Would you say as much can be achieved with C# as Python?
foxwood
Posts: 390
Joined: Mon Jul 23, 2012 2:54 pm

For a noob, I'd say Visual Basic is the way to go. You already have a handle on VBA (and therefore objects) so switching between VBA and VB.NET is straightforward. This gives you the skill set for automating using the BA / Excel connection and for writing your own "deeper" standalone programs in vb.net.

Note that you are not restricted to only using vb libraries just because you program in vb - with a bit of easy tinkering you can link with Windows libraries or .NET assemblies written in any language if they provide useful functionality. Also, you can call .net libraries from Excel VBA so you can have your own library available in both Excel and standalone programs.

As a long-in-the-tooth programmer, I only use vb.net for trading and even run it live in Debug mode rather than Release - nothing I do is seriously time critical so I take the easiest route I can.

For serious time critical stuff I would use assembler and/or C with C++ as the next "slower" step and any of the .NET languages as the slowest. The joy these days is that you can mix and match languages and objects easily whereas once upon a time you'd be stuck with the lowest common denominator that the project demanded.
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

HRacing wrote:
Tue May 30, 2017 2:22 pm
Thanks for your thoughts, VBA has been more than helpful in a few projects for me but just wondered what the 'pro's' were using as there way of automation.
There's some extremely complex systems out there in VB land, don't underestimate it. The sort of coding you're looking to do won't tax any language.

Different people take to different things, so perhaps you could draw up your shortlist, spend an hour looking/reading about each, and see which one clicks. I'd say at this stage you almost can't go wrong, because anything you learn will transfer to other languages. The difference between programming languages is more like the difference between Spanish and Italian rather than the difference between Greek and Manderin.
User avatar
HRacing
Posts: 278
Joined: Tue May 14, 2013 11:25 am

Cheers for all the advice guys
LinusP
Posts: 1871
Joined: Mon Jul 02, 2012 10:45 pm

Python is a high level language built on top of C, with that you get simplicity (no pointers / garbage collection) but you lose speed. C# is slightly lower giving you greater control but added complexity. As mentioned above do some reading, stack overflow recently did a survey on what is popular / liked, anything with visual in the title tends to be at the bottom...
Post Reply

Return to “Betfair Exchange API”