Fantasy sports are all about making the right calls—do you trust your gut, or do you trust the data?

In fact, sports and data are a powerful combination and nowhere is that more evident than in the world of fantasy sports. Whether it's the excitement of the Premier League or the strategy behind your fantasy lineup, the passion for sports runs deep. And when you bring data into the mix, that passion can turn into a winning formula.

Senior Principal Business Operations Specialist Bas Belfi in the SAS Belgium office has never met Principal Operations Research Specialist Sertalp Cay, who lives in Cary, NC, in person. But they’ve worked on several sports analytics projects over the last couple of years and have now recorded over 94 podcasts together, built a website and assembled an online community of well over 20,000 people—their topic: Fantasy Premier League (FPL) and analytics.

Optimization in fantasy sports 

FPL is a free online fantasy game for the most popular soccer league in the world, the English Premier League, played by 10 million people worldwide. Like any fantasy sport, you pick your players, build a team and compete throughout the season to win matches and points and become champions like last year’s winner Jonas Sand Låbakk.

On their podcast, Belfi and Cay don’t just get together to discuss game results; they intersect sports and optimization. Cay enjoys the beautiful game and also specializes in optimization. After talking to Belfi, a diehard football fan, they realized that in fantasy, there are two pieces: one to make predictions and one to make decisions.

“Some people were already making predictions from available data, but you need an optimization model to make a decision, and nobody knew how to turn predictions into decisions,” said Cay. But he knew SAS and open source could.

Showcasing the power of optimization

He started with Python to showcase how optimization works. Optimization is all about making the best use of given resources. It's a mathematical approach to finding the most effective solution to a problem by maximizing or minimizing a certain objective within given constraints. In fantasy football, it translates into maximizing projected points while adhering to budget and team restrictions by generating long-term transfer plans. Cay implemented a mixed-integer linear optimization model, which can optimize the set of decisions for fantasy players.

The model is written using sasoptpy, a SAS Python optimization modeling package, for which Cay is the lead developer, but it can also be hooked up to open-source solvers. Cay shared how the optimization model can be written from scratch in a step-by-step tutorial series on YouTube and posted the source code on GitHub. Over time, more people became interested and started to contribute. Today, the solver has over 40 custom options for people to generate optimal sets of decisions for short-term periods on their machines.

One challenge with open-source solutions is that they can struggle with larger datasets due to scalability limitations. That’s where our SAS optimization solvers excel. It’s designed for high performance and can efficiently generate decisions for longer time horizons and multiple scenarios. “Optimization is a powerful tool,” says Cay, “and you need advanced algorithms and robust implementations to solve large-scale problems quickly. We can achieve this with SAS, providing faster and more comprehensive solutions than open-source alternatives.”

SAS' optimization capabilities enable him to solve problems even under stochastic events, helping him find the optimal team and decisions even when things go wrong, like unexpected injuries and player rotations. Open-source optimization solvers are a great starting point, but for business-scale problems, you need SAS.

Cay develops models to (in theory) win games. But how does it fare in the real world? That’s where Belfi comes in. The two have been using their complementary skills for the podcast; Cay is the data scientist, preparing and talking about the analysis, while Belfi is the marketer who prepares the scripts, plays a bit more of the moderator role in the discussions and works on the promotional side of things. They use their online platform to see whose team will outperform the other week to week and talk data and analytics while they are at it. In the podcast, they jokingly refer to it as “Data vs. Grass.”

Man vs. machine 

In the four seasons he played, Cay finished in the top 5,000 global players (top 0.05%) twice. Moreover, this year’s winner, Labakk, is a member of the Analytics community Cay started, with over 1,800 members. He used analytics and optimization for his decisions throughout the season.

“There were no other regular podcasts associated with the analytics side of FPL,” said Belfi.

The two have weekly discussions, informing people about soccer, analytics, data, open source and SAS. Unlike other man vs. machine competitions (I’m thinking about how optimization has infiltrated the worlds of poker and chess), this is a friendly conversation where sometimes you win and sometimes you lose.

“Underdogs win games all the time,” laughed Cay. There’s no guarantee you will always win, but that makes it fun. What's really exciting is that the role of analytical gameplay in FPL has been growing over the last couple of years, and I'd like to think that we contributed to that trend. The fact that this year's FPL winner is known to be an analytical ‘manager’ is a testament to it.”

Cay hopes their content accomplishes two goals:  

  1. Encourages people to learn the technology and become interested in analytics in general. He provides tutorials for anyone to use optimization to solve simple problems. Then, people can build from there and create custom rules based on fan favorites. For example, you are a Liverpool fan. How can you optimize your lineup without Manchester United players?
  2. Provide decision support and drive awareness of SAS. The podcast isn't promoted as a SAS podcast, but Cay and Belfi hope people will get introduced to SAS when looking at their profiles and backgrounds. Getting people to use SAS and open source to generate ideas will build on the community.

Get involved 


WANT MORE GREAT INSIGHTS MONTHLY? | SUBSCRIBE TO THE SAS INSIGHTS NEWSLETTER

Share

About Author

Ginny Inman

Ginny Inman loves telling people’s stories. Having studied at the University of North Carolina Wilmington and earned her master’s degree from North Carolina State University, she uses her experience to communicate through writing and video production for SAS’s internal communications team. She enjoys using creative communication solutions to build projects from the ground up for SAS employees around the world.

Leave A Reply

Back to Top