What I’m working on…
Fantasy football has never really been my thing. It’s very frustrating by the time you get to the end of the season having dealt with injuries and underperformers. Instead, I’m a big fan of survivor pool! Rules vary between pools but the one I participate in goes as follows:
- You can only use a team once
- Weeks 1-9 you select a single team
- From Week 10 on, you select two teams a week
This can become rather challenging since in a single season you utilize 23 of the 32 teams in the league. When do you decided to actually use the Jets, Colts or Browns?!?!
I’ve had success over the years in finishing in the Top 100 in a pool that consists usually around 7,000 players. Not bad. In the future however, I wanted to take a more analytical approach to the season. I utilized Python to create a program that will look at each teams odds over the season and select what week in the season they have the best chance of winning. The output is a list of what team to select it each week.
I’ve tried to focus on structuring my programs rather than putting eveything in a single script. In this case, I have one script that utilizes BeautifulSoup to create a dataframe of statititical data pulled from a website. My other script takes the dataframe and creates the output table for team selection.
My results so far have been very promising. There weren’t a lot of people that expected Josh Allen to route the Minnesota Vikings in Week 3. I’m exicited to see how the rest of the season goes.
Week | Team | Outcome |
---|---|---|
1 | New England | W |
2 | New Orleans | W |
3 | Minnesota | L |
4 | Jacksonville | W |
5 | Carolina | W |
6 | N.Y. Jets | W |
7 | Atlanta | W |
8 | Pittsburgh | W |
Some improvments I still need to make to the program.
- Low chance but it does occur where a team is selected twice in the selection algorithm.
- Create command line interface
- Make the program more adaptable to allow multiple teams selected in the later weeks based on the pools rules and regulations.
I may change the overall functionality of it, we’ll see. But I have the data all structured so I can chose to do what I want with it after that.