RotoGuru Computer Forum

View the Forum Registry

XML Get RSS Feed for this thread


Self-edit this thread


0 Subject: How These Sites Work?

Posted by: VP - [259141319] Mon, Dec 06, 2004, 01:05

Thanks in advance...

I have to say I'm pretty amazed how sites like this and other "personal" fantasy sites work. I understand the basics of PHP and SQL and all that...but I'm wondering how you guys are actually accessing the statistics used for many of the features I've seen. I'm fairly certain you'd have to be using an existing database...am I right about this? If so how does one gain access to these databases? Would I have to pay, or know people, or just look it up somewhere? I would love to put up a few webpages for my fantasy teams to sort statistics for me and things like that...anyone have any insight for me??
1VP
      ID: 259141319
      Sat, Dec 11, 2004, 14:59
Heh this it the second time I've posted this here and it's the second time no one has responded...even though I'm fairly certain that a few of the regular posters here actually run sites like this...is it illegal or something?? I cannot find any information on how to do this!!
2TB
      Leader
      ID: 031811922
      Sat, Dec 11, 2004, 15:11
I remember reading your initial post and being unsure what you are talking about. Perhaps if you were a bit more specific in what you are looking for. There is no super secret knowledge or anything illegal on this site. If you are looking for the tools used to collect data from a specific sport, you might want to try posting a thread in that forum. Sorry, I am not more help on this, but I don't use any of the tools.
3VP
      ID: 259141319
      Sun, Dec 12, 2004, 02:55
Its basically a general question asking how a site like this gains access to its statistics. I wasn't implying that it was illegal, just poking fun at how secretive it seems.

I know Guru doesn't manually enter all the stats for his site, and I also am fairly certain that he doesnt have his own personal stat service to automate things, so I'm wondering if he's paying for some service like Stats Inc. or if he's using a public database that I could also try using.

It seems like there are several people here (RSF, Guru, and Koala to name a few) who are running sites like this. I would be surprised if they all were making enough money to pay for a stat service, so I'm wondering how they did it.

Is that clearer?
4Guru
      ID: 330592710
      Sun, Dec 12, 2004, 07:55
You have two options:

1. Pay for a stats service. It's expensive. For a personal site, you'll probably want another option.

2. Write a program to parse the stats from some other publicly available source. You can either write a macro in excel to load in web pages which provide the stats you want, and then reorganize them inside the spreadsheet before putting them back onto a web server for your program to access. Or you can write a program that runs on your server, reads the stats web pages, parses the stats (i.e., interprets the html code and finds the stats from within the page code), and puts them in a file for access by other programs.

There is no cookie cutter approach for this. The best approach depends on your budget, your programming capabilities, your server capabilities, and the scope of the project you are trying to tackle.
5VP
      ID: 259141319
      Sun, Dec 12, 2004, 09:49
Ah thanks guru. So you can write programs in something like PHP that actually go through html and take the statistics? That sounds crazy. I thought for sure there was just some magical database somewhere that you guys were using. Hmm, I'll look into trying to write such a program...sounds like it 'll be quite a challenge.

Thanks for responses you guys :)
6RecycledSpinalFluid
      Dude
      ID: 204401122
      Thu, Dec 16, 2004, 23:14
Honestly missed this one (or read it and didn't really understand the question.)

I don't really have any websites up and going (other than the nightly Boxscores), and that (depending on how you access them) is on a "Free Host" or on my own little Web Server, there is not really any cost involved for me (you get what you pay for! :)

The Enhanced Boxscores are just a VBScript in ASP that reads and interprets the Yahoo Boxscores, adds in my extras (the PSC and TSN scores, the sartible columns) then creates the HTML code for the new features.

The Player Ownership data I post here is just reading each team (via a VBScript which posts it in my database). The tables I post here are just some webpages (in VBScript in ASP) that I repost the resulting HTML code here.

So, in a nutshell...what Guru said.
7Gmoney
      ID: 440322814
      Fri, Jan 28, 2005, 18:42
Not sure where to put this but I cleaned out my cookies and I need to be reminded how to get my "donor" status back.

Thanks

G
8Farn
      Sustainer
      ID: 451044109
      Fri, Jan 28, 2005, 18:46
in this thread click the 2nd drop down box and choose Gurupatron Validation.
9RecycledSpinalFluid
      Dude
      ID: 204401122
      Fri, Jan 28, 2005, 18:47
GuruPatron Validation
10???
      ID: 531023137
      Sat, Jan 29, 2005, 16:39
How much does stats inc. charge for there information (roughly) monthly charge? yearly?

And do they offer a demo feed to allow you to build a site off there content?

just curious.

thanks
11rolf1001
      Donor
      ID: 038118220
      Mon, Jan 31, 2005, 19:54
#5
In case you need some sample code in PHP to fetch data out of a HTML resource, i can send you an exmaple to your e-mail address. It isn't that difficult. In fact, nearly anything you can get with your browser, you can get with a programming language e.g. PHP.

PS: Sorry for answering a little late, didn't read your posting earlier.
12 VP
      ID: 259141319
      Sun, Feb 13, 2005, 17:53
#11
I'd appreciate that...my email is nwhorton@gmail.com
I'd been working on a PHP script to parse HTML box scores, but I think it's going to be really hard to use that in order to store the stats into a database. Maybe I could save the text I find as a .txt file and somehow use that instead? Right now I've turned to looking for an XML box score feed...unfortunately I can't find one...
13rolf1001
      Donor
      ID: 038118220
      Mon, Feb 14, 2005, 17:54
With regular expressions, it isn't that hard to extract the stats. I sent you an email with an example for a nba.com boxscore.

14 WarCrimes
      ID: 592502116
      Mon, Mar 21, 2005, 17:51
Hey rolf1001,

Would you mind sending me that PHP example of extracting the stats from an nba.com boxscore? I'd appreciate it. My email is CVnation@hotmail.com

Thanks in advance.
15 Isaac
      ID: 422242517
      Fri, Mar 25, 2005, 18:24
rolf1001, I'm hoping to do the same thing. I've emailed VP and WarCrimes in case this thread is lost and forgotten, but if you read this, I would greatly appreciate it if you could send me the same info.

I'm trying to build something in ColdFusion that can strip data from an HTML boxscore and get it into a database for reporting.

Thanks.

Isaac
16rolf1001
      Donor
      ID: 038118220
      Mon, Mar 28, 2005, 19:26
Sorry, didn't check this forum.

You can find a (very simple) script here:
Sourcecode: http://www.kaiser-online.info/rotoguru/rotoguru.phps
Sample boxscore used: http://www.kaiser-online.info/rotoguru/boxscoreprint.html
Output: http://www.kaiser-online.info/rotoguru/rotoguru.php

It does work on all my systems, but VP had some weird problems with it (no idea why).
17deraynman
      ID: 36822250
      Thu, Apr 07, 2005, 01:49
rolf thanks, those are very useful links. i was wondering if anyone has macro experience in excel. it would solve all of my problems if i could figure out how to get excel to automatically retrieve how many homeruns alex rodriguez has in 2005 (from yahoo or any html source), and place it in cell A1. if anyone can send me in the right direction it would be greatly appreciated.
18 Ryan
      ID: 576532313
      Sat, Jul 23, 2005, 14:54
Stats Inc. has a "snap" service that is fairly robuts but they are still hosting it and you just frame it into your pages - probably not what you are looking for and they chage $1k per month for this service pluse a rev. share on those pages.
RotoGuru Computer Forum

View the Forum Registry

XML Get RSS Feed for this thread


Self-edit this thread




Post a reply to this message: (But first, how about checking out this sponsor?)

Name:
Email:
Message:
Click here to create and insert a link
Ignore line feeds? no (typical)   yes (for HTML table input)


Viewing statistics for this thread
Period# Views# Users
Last hour11
Last 24 hours11
Last 7 days22
Last 30 days76
Since Mar 1, 200797281066