Collecting Data To A Spreadsheet

Discussion regarding the spreadsheet functionality of Bet Angel.
Post Reply
Bigd85
Posts: 59
Joined: Fri Oct 26, 2018 9:37 pm

Afternoon guys,

With the automation and signals I can gather a lot of the information on a race but this then requires me to input into a spreadsheet to collect the date.

I work with excel on a daily basis and believe myself to be fairly good with calculations and problem solving etc but im struggling to get information from BA sent to a spreadsheet

Ideally I would like to gather the following information for a horse race

Course, Distance, Going (if BA does have the ability to do this), horses in the race, stall number, if i knew how to gather this i could then work out how to gather the rest of the information i need.


Can this be done???

Thanks

Dan
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

If you're reasonably proficient at Excel/VBA it should be straightforward, except the Going which isn't in the BF data.
I don't have the time atm to search for what you need but if you search the forum for 'data capture' there are several downloads that will get you started, although you might need to modify them as everyone has a slightly different requirement. Unless you need millisecond data then BA should be able to export all you need without having to work directly with the api.
Bigd85
Posts: 59
Joined: Fri Oct 26, 2018 9:37 pm

ShaunWhite wrote:
Thu Jan 03, 2019 2:13 pm
If you're reasonably proficient at Excel/VBA it should be straightforward, except the Going which isn't in the BF data.
I don't have the time atm to search for what you need but if you search the forum for 'data capture' there are several downloads that will get you started, although you might need to modify them as everyone has a slightly different requirement. Unless you need millisecond data then BA should be able to export all you need without having to work directly with the api.
Thank you shaun, I can do calculation and such but never the vb and data gathering side of it. I’ll have a look around later this evening and see what I am able to find.

Cheers
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

Bigd85 wrote:
Thu Jan 03, 2019 2:54 pm
Thank you shaun, I can do calculation and such but never the vb and data gathering side of it. I’ll have a look around later this evening and see what I am able to find.
It might take you a day or two, but it'll be worth it i'm sure and as I said, there's enough examples out to mean that you don't need to start from scratch. Modding something is always a good way to learn. If you can handle formulas then I'm sure you could handle them in vba.....all you ever need do is read cells, manipulate the values, and write a cells. And maybe maintain a line counter saying where that read/write happens if you're planning on storing a change history. No need to get sidetracked or daunted by all the other fancy stuff.
Bigd85
Posts: 59
Joined: Fri Oct 26, 2018 9:37 pm

ShaunWhite wrote:
Thu Jan 03, 2019 3:44 pm
Bigd85 wrote:
Thu Jan 03, 2019 2:54 pm
Thank you shaun, I can do calculation and such but never the vb and data gathering side of it. I’ll have a look around later this evening and see what I am able to find.
It might take you a day or two, but it'll be worth it i'm sure and as I said, there's enough examples out to mean that you don't need to start from scratch. Modding something is always a good way to learn. If you can handle formulas then I'm sure you could handle them in vba.....all you ever need do is read cells, manipulate the values, and write a cells. And maybe maintain a line counter saying where that read/write happens if you're planning on storing a change history. No need to get sidetracked or daunted by all the other fancy stuff.
Thanks, i have had a bit of a download and play and must say im completely lost. i think i need to study vba again!

I just wanted to gather date, time, course, horses, stalls and lowest lay values for each race over the course of a day.

i can get all of this from automation but have to input myself at the end of the day which can get very annoying.
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

As I said it might take a day or two. I count days at about 14hrs man hours apiece :D I wouldn't expect you to have got far in an evening. You'll soon make the time back by not having to do it longhand and I'm sure other ideas will spring from it. Once you've mastered the basics you're only limited by your imagination.
Bigd85
Posts: 59
Joined: Fri Oct 26, 2018 9:37 pm

ShaunWhite wrote:
Thu Jan 03, 2019 10:21 pm
As I said it might take a day or two. I count days at about 14hrs man hours apiece :D I wouldn't expect you to have got far in an evening. You'll soon make the time back by not having to do it longhand and I'm sure other ideas will spring from it. Once you've mastered the basics you're only limited by your imagination.
ill get there, just trying to get my head around things.
spreadbetting
Posts: 3140
Joined: Sun Jan 31, 2010 8:06 pm

What you should start with is to decide what data you wish to collect, when you want to collect it and how you want it arranged on your collection sheet.

Copying data with VBA requires little more than saying one range equals the range you wish to copy.

If you get stuck just stick up any code you're stuck with and I'm sure you'll get help with it.
User avatar
ShaunWhite
Posts: 9731
Joined: Sat Sep 03, 2016 3:42 am

Dunno if these'll help.

viewtopic.php?f=17&t=16116&hilit=help+v ... 10#p148328
viewtopic.php?f=19&t=17480&hilit=vba
viewtopic.php?f=19&t=16103&p=147998&hil ... ba#p147998

Planning is underated too, it really helps to get out an old fashioned pencil and paper and describe exactly the steps you'll like to see happen. Remember coding is like describing a process to an absolute idiot, it needs you to describe what's necessary in every tiny detail, your pc doesn't 'assume' anything. By stringing these small simple instructions together you create the whole.
Bigd85
Posts: 59
Joined: Fri Oct 26, 2018 9:37 pm

Thanks guys


I’ve managed to grab a load of what I need off of the betangel sheet which is included.

This gives me a start so hopefully I can build on this
spreadbetting
Posts: 3140
Joined: Sun Jan 31, 2010 8:06 pm

If you can get your head around arrays it's well worth the effort of simply collecting all your copied data into a Public array held in memory and then only dumping that to a text file or some separate data sheet once you've finished collected data after each race/day.
Post Reply

Return to “Bet Angel - Spreadsheet / Excel chat”