Fantasy Analyst Guide

Introduction to Fantasy Analyst

Fantasy Analyst is a windows desktop program for daily fantasy sports players. It includes a variety of advanced features for analyzing historical statistics and building lineups:

  • Neural Network Projection Models - Use neural network regression models that have been trained on historical data to determine baseline projections. Adjust inputs as you wish to update the projection values.
  • Custom Stats - Write your own SQL queries to define custom stats, using seasons worth of data that you can download to your computer.
  • Variance Lineup Optimizer - Generate lineups that with an optimizer than can factor the variance of player scores, and covariance of scores between player pairs. Increase variance to improve your chance of making high-scoring lineups for GPPs, or minimize variance to try to win 50/50s more consistently.
  • Projection Accuracy Analaysis - Easily save, import, and export different projection sources. Measure their historical accuracies and compare them to make sure you are using the best source available.
  • Contest Management - Fantasy Analyst provides an easy interface to manage your contests on DraftKings and FanDuel, allowing you to quickly export all lineups to CSV files.
  • Entry History - View your history of wins and losses. Determine what contest types you are most profitable in, and which require improvement.

The focus in developing the app was to make the most rigorous set of software and math tools available for DFS players. General DFS strategy is not covered on this site, which can be found elsewhere online.

It's important to treat the Fantasy Analyst app as an analysis tool and to understand how the features work before using them. To ensure this, it is highly recommended that you read this guide as you use the app. The app is not intended to simply produce winning lineups automatically without any additional user input. Think of it like a calculator that can help you on a math test, rather than a cheat sheet of answers. In addition, be sure to watch the tutorial videos on the website that go over some of the main features.

The guide is organized into several sections:

  • Tutorials - Check this section first for basic tutorials on how to use Fantasy Analyst. This includes a quick start example showing how to build lineups and export them to a DFS contest.
  • Using Fantasy Analyst - In this section, detailed descriptions of all windows, buttons, options, etc. in the app are provided.

This guide will be continously updated, so be sure to check back here periodically for new information posted.

Quick Start Tutorial

This tutorial will go through a step-by-step example on how to use some of the basic features of Fantasy Analyst for entering a DraftKings MLB contest. If this is your first time using the app, this tutorial should provide all of the information you need to get started with Fantasy Analyst. The same ideas covered here apply to the other sites and sports available in the app, so don't worry if the ones you want to use the app for are different. An earler video example for NFL on FanDuel is provided on YouTube as well, which you can view here.

Starting Fantasy Analyst

When you start Fantasy Analyst for the first time, the app will likely update itself to the latest version and restart. After this, you will be prompted to log in. Simply enter the username and password that you registered with on the Fantasy Analyst website. If you haven't created an account yet, go to https://fantasy-analyst.com/register to make a new one.

Once you've logged in, we'll need to choose the site, sport, date, and slate for the contest that we want to enter in. You can select these from the top of the window. As previously mentioned, I'll be choosing DraftKings for the site and MLB for the sport. Since the date at the time that I'm writing this tutorial is 5/12/2018, I'll go ahead and select that date.

After choosing the date, you will be prompted to download the data for that date (since we have not downloaded it already). Clicking OK and waiting a few seconds, we will now see data players and games being shown in the Projections tab as shown below.

Tutorial screenshot

If the data for the current date was already downloaded at an earlier time, it is always a good idea to refresh it before making lineups for your contests. This will ensure that we have the correct starters and any additional updates since our last download. To do this, click the Download Selected Date button near the top right corner of the window. After a few seconds, the data will now be updated and reloaded in the window.

Configuring Displayed Columns

The primary purpose of the Projections tab is to allow us to determine player projections, add/remove players or games from consideration when building lineups, and browse different stats of interest. One of the first things we'll want to do is configure the Projections/Stats and Game Information windows here the show us the information we want. Looking at the Projections/Stats window, we can see a variety of default columns are currently shown. The first is the Selected column, which indicates whether or not a player will be available when we build our lineups. We can uncheck the checkboxes in this column to exclude players we don't want to use at all in our lineups. The next columns are basic information that include the player name, team, and opponent. After these, the Proj. Points column is shown in magenta. This column holds our current projections for all players, and can be edited by clicking on the value and changing it as desired. The Proj. Points column is loaded with values from the blue 3rdPartyProj column initially, which contains projected fantasy point scores from FantasyData.com for the selected site. Site-specific information is then shown in green that include the Position, Salary, and Pt/$1K columns. Additional columns follow with a variety of additional information. Those colored in yellow are editable inputs for the neural network projection models available in the app. Some such as the AvgPoints column are currently blank because they have to be calculated from the app by clicking the Generate Neural Network Projections button at the top. The Game Information window below is organized similarly. Here you can select or remove all players from specific teams. Some information of interest such as the Vegas odds and weather forecasts is currently displayed. 

Let's first set the columns that we want in the Projections/Stats window by clicking the Edit Columns button in the top-right corner of that window. This will bring up the Column Settings editor as shown below:

Tutorial screenshot

As you can see here, we can change the what columns we display in the Projections/Stats window, along with their left-to-right order. A number of stats are available to choose from the Available Columns list box. Adding,removing, and re-ordering columns can be performed by clicking and dragging them. Please note that most of the default stats display projected values from FantasyData.com when the Proj/Stat Display option is set to Projections, and the actual result after the player's game has finished if the Historical Result option is selected. If you wish to calculate your own stats based on historical data, please see the tutorial on creating custom stats.

Since I'm not going to be using the neural network projection models in this example, I'll go ahead and remove most of the columns associated with it and add in PitchingEarnedRuns and PitchingStrikeoutsPerNineInnings to get some additional information to help in selecting pitchers. I'll also keep BattingOrderProjTeamScore, and ProjOppScore. Once I have the columns I want in the correct order, I can click Save to save this configuration. My Projections/Stats window now has the columns shown below:

For the purpose of keeping this example short, I wont change the columns in the Game Information window. However, I recommend that you also take a look at the available columns for each sport and adjust the displayed columns according to your preference.

Building a Lineup

Now that we've configured the windows in the Projections tab to display the information we want, we'll now want to start looking for players and teams that we want to target or exclude when building our lineup. First, we'll want to make sure we've chosen the correct slate. This will both set the rules for building lineups and remove games that are unavailable to choose players from for that slate. By default, the main slate is selected so let's leave this as is.

Let's now look at starting pitchers and determine which ones we will want to use for our lineups. We can set the Projections/Stats window to only show starting pitchers by clicking the filter icon in the Position column and selecting "SP" as shown below:

You may also only want to filter the Selected column to only show "True" values, in order to hide players that are not currently available for selection.

Let's now try building a lineup by choosing one pitcher to include, a team to stack for our batters, and then using the standard score optimizer to give us the optimal lineup with our current projections. Quickling looking at the projections and stats displayed, Charlie Morton appears to be a decent candidate for a pitcher so let's assume we'll want to lock him in. As for teams facing a weak pitcher, COL appears to be in a good situation against Brent Suter and has the highest implied run total from the Vegas odds, so let's also assume we want to stack 5 hitters from COL.

We'll now go to the Lineups tab to start building our lineup with these constraints. This tab should appear as shown below:

In this window, the lineups that we generate will be shown in the Lineups window. From the Player Paramters window, we can lock or exclude players and adjust their projections or ownership constraints. If we want to manually create or edit lineups player-by-player, we can do so from the Lineup Editor window. Finally, we can assign the lineups we've created to contest entries imported from DraftKings or FanDuel in the Contests window.

Let's first start by locking Charlie Morton into our lineup. To do this, search for his name in the Player Parameters window, and then click on the checkbox so that a check mark appears next to his name as shown below:

Now, let's add in the constraint for our COL stack. To do this, we'll want to enable one of the "Hitter Stack" options in the MLB Constraints section at the top. We can then select the number of hitters we want to require in the stack, along with the team. I'll assume we want to stack 5 hitters from COL, setting the option as shown below:

Now that our constraints are ready, we can click the Generate Lineups button to make our lineup. The standard Score Optimizer configured to Optimize Points Projected is selected by default, which will find the lineups with the highest projected score given the constraints we've set. Note that the # Lineups to Generate option in the Optimizer section is set to 1, so the optimizer will only generate one lineup. However, we can generate multiple lineups if desired, and set maximum ownership constraints for players in the Player Parameters window to limit how often players are used across those lineups. After clicking the button, you will now see a lineup added in the Lineups window with the name Lineup1. The total projected score for this lineup, the players used, and the total salary are displayed. Once the games for the current date have completed, the ScoredPoints column will show the actual score this lineup produced, allowing you to compare to projected and actual result. The ProjectedVariance column is currently blank, but can be used to show the estimated variance of the lineup after generate variance/covariance estimates for players in the Variance tab. If I right click on the lineup, I can choose the Lineup Player Info option to see more details regarding each player used in the lineup in a new window as shown below:

Importing and Exporting Contest Entries

Now that we've created our lineup, we'll want to export it to a DraftKings contest. I've already entered a dummy lineup in a contest, so I'll now need to download the corresponding contest entry CSV file from DraftKings. To do this, I'll go to the DraftKings website, click Lineups, and then click Edit Entries. This brings up a page like the one shown below:

With the correct sport, style, and slate selected, I can click the Download button to get the CSV file. After I've saved the file somewhere, we can go back to the Fantasy Analyst app to import it. To do this, I just need to click the Import button in the Contests window and select the CSV file that was just saved. The Contests window will now show the contest entry from DraftKings as shown below. If we click the contest entry, the dummy lineup entered will be displayed in the Selected Contest Lineups window.

We'll now want to replace the current lineup in this contest with the one we just created. To do this, I'll right click on the lineup we previously generated and select Replace in Contest. This option allows us to replace the lineups in contests we select with the ones we have selected in the Lineups window. A window will now appear, prompting us to select which contests we want to replace lineups into. We'll leave our one contest selected and click Replace.

After this step, the dummy lineup from our contest should now be replaced with the new one we created. You can double check this by clicking on the contest and looking at the lineup in the Selected Contest Lineups window. We can now export our contest entry by clicking the Export button. Doing this will open a table with all lineups and contest entries from the Contests window that can be copied and pasted back into the original CSV file. To copy the table, simply right click anywhere and click the Copy option.

Now, I'll open the original CSV file that was downloaded from DraftKings, and paste the table in at the beginning of the 2nd row as shown below.

The CSV file can now be saved and uploaded back to DraftKings by clicking the Upload CSV button on the same page from where we downloaded the CSV file. If everything worked correctly, a message will indicate that all of the lineups were imported successfully.

Historical Data

Now that you understand the basics of how to use the app, one of the next things you'll want to do is download historical data from past seasons. A variety of features can use this data in this app, such as the neural network projections or the custom stats you can define. To do this, go back to the Projections tab and click the Database Manager button near the top right. Doing this will bring up the MLB Database Manager window, which you can use to save or delete MLB data.

To download all MLB historical stats available, just leave the start and end seasons at their default values and click Download. The historical stats will begin download, and this may take a few minutes before completing. Once this is complete, you will now have all MLB data from the beginning of the 2016 and onward saved on your computer for analysis. To try this, close the database manager, right click on a player in the Projections/Stats window, and select Display History. You should now see a window appear that displays the historical results of fantasy points scored along with other information that can be configured by editing the columns as before. Doing this for Adam Duvall produces the window shown below:

It is recommended that you always keep your database of historical stats up to date. If a number of days have passed since you've last updated, you may want to use the database manager to re-download the data for only the current season. However, if only a couple of days require updating, you can simply select those dates one by one and click the Download Selected Date button to update the data for each.

Top Menu

The top menu bar of Fantasy Analyst is shown in the screenshot below, highlighted in red. Tabs for the different windows available in the app are shown on the left side. Game selection options for the site, sport, date, and slate are shown on the right half.

 

Tabs: The tabs here let you navigate to the different windows in the Fantasy Analyst app. A brief description of each is below:

Projections: This tab is primarily intended for determining player projections before using the optimizers in the “Lineups” tab to build lineups. Historical stats for players and game information can be reviewed in this window as well.

Variance: From here, variance and covariance of scored fantasy points can be measured between players or positions for the selected site and sport. The variance and covariance values calculated can be used for the variance optimizer in the “Lineups” tab.

Lineups: This tab allows you to choose an optimizer and build lineups from it according to the settings you specify. Contests from FanDuel or DraftKings CSV templates can be loaded in here as well for easily exporting lineups.

Projection Accuracy: Measure the historical accuracies of different projection sources and compare them to each other to make sure your using the best source.

Entry History: Load in CSV contest history files from FanDuel, DraftKings, and Yahoo to track your history of wins and losses.

Game Selection Options: In order configure Fantasy Analyst for the contests you want to play, you must specify all of the options on the right side of the top menu:

Site: The site for the contests you want to enter in. Current sites supported are FanDuel, DraftKings, and Yahoo. This option will affect factors such as projected scores, rules for building lineups, etc.

Sport: The desired support. NBA, NFL, and MLB are currently available. More sports will be added in the near future.

Selected Date: Here, you should select the start date of the contest you’ll be entering.

Slate: After selecting a date, this menu will show the available slates for the chosen site and sport. Selecting a slate will automatically add/remove the appropriate games and players, and set the correct rules for building lineups. Selecting a slate for FanDuel or DraftKings also ensures that you can export your lineups to contests in that slate. “No slate” options are available for any date, which simply assume all players and games are available for selection. A separate “no slate” option is shown for each rule type, letting you choose what rules to use for lineups created.

Projections Tab - Overview

This tab is primarily intended for determining player projections before using the optimizers in the “Lineups” tab to build lineups. Third party projections from Fantasy Data and the neural network regression model projections are available to use as baselines. However, you may also easily import your own projections from CSV files. Fantasy Data also provides projections for a variety of player stats other than Fantasy points, which can be displayed by configuring the table columns appropriately.

A variety of additional information can be accessed from this tab as well to help select players and adjust projections. This includes information on the current games such as Vegas odds and weather conditions, historical player stats, and custom stats that can be defined through SQL queries.

Once the games for the selected date have completed, you can also switch this tab to a "Historical Result" view, allowing you browse the actual results from that date.

 

Projections Tab - Settings and Options

Player filters: Quickly add/remove players based on filtering criteria. Removing players simply means that they will not be available to use when building lineups. Three different parameters are available to filter on; the ratio of players’ projected fantasy points per $1K of their salary, total projected projected points, and salary. After moving the sliders to the desired ranges, you can click the “Filter” button to remove any players that do not fall within the set ranges of these parameters, and add players that do. On the right side, the total # of players currently selected

Projection/Stat Display: In this box, you can choose whether to display projected or historical stats in the “projections/stats” window. With “Projections” selected, you can see the projected player scores from Fantasy Data in the 3rdPartyProj column, along with projected values for certain player stats (such as minutes for NBA). Changing to “Historical Result” replaces the 3rdPartyProj column with a ScoredFantasyPoints column that shows the fantasy points actually scored by the player. This will also change the stats displayed to show their result from the game.  Historical stats may not be available to see until after the games have completed.

Neural Net Projections: Clicking the “Generate Neural Network Projections” button calculates the default neural network projection model inputs for all players. If all inputs were calculated successfully, a projection value will be shown in the NeuralNetProj column.

Projection Sets: Click the Save button to save the current projections in the Proj. Points column to a projection set, allowing you to measure the historical accuracy of that set in the “Projection Accuracy” tab. You can either choose an existing set to save to from the drop-down menu, or save a new one by typing in a new label. In addition, you can load the projections from a set by clicking the Load button if you’ve already saved projections for the selected date to that projection set. 

Import/Export: Click “Import CSV” to import a CSV file with projections to load for the current players. Player names should be listed in the first column, with projection values in the second column. You will be notified with warning messages if there were any player names not found, or if there are suggested name substitutions due to minor spelling differences. Click “Export CSV” to export the projection list to a CSV file. 

Data: Two buttons are available here:

Download Selected Date – This button will re-download all of the projected and historical stats for the currently selected date. It is typically a good idea to click this button before you start modifying projections or building lineups to make sure you have the latest data.

Database Manager – Clicking this button will bring up the database manager window. From here, you can download seasons worth of projected and historical stats and delete data such as projection sets you no longer want to keep. 

Database Manager Window

Data Tab – In the data tab, you can download projected and historical stats over multiple seasons for the current sport, or delete data from the various databases used for Fantasy Analyst. To download the stats, simply choose the start/end seasons you want to download data for and then click the “Download” button. To delete data, select the type of data you want to delete for this sport in the options under “Database Delete” and then click the “Delete” button.

 

Projections Tab – From the projections tab, you can delete projection sets that you have previously saved.

Projections Tab - Projections/Stats Window

The projections/stats window allows you to view a variety of information for the players in the slate you’ve selected, adjust their projections, and select the ones you want to use for building lineups. In the “Proj/Stat Display” box, ensure that “Projections” is selected if you want to display projected player stats. If the games for the selected date have completed,you can instead select “Historical Result” to show the historical stats from those games.

Projection values in the “3rdPartyProj” column and any injury-related columns are automatically updated over time. If you want to update the values in the “Proj. Points” column to use the latest values, highlight the players you want to load the projection for, right click, and choose “Use 3rd Party Projections.” If you wish to see when the last update was performed, the “Updated” column can be loaded in the window to show this.

Some of the columns in this window are colored to help distinguish their purpose. A description of what the colors signify is provided below:

  • Magenta – The projected point values to be used when generating lineups with the optimizers. These can be manually edited.
  • Light blue – These columns represent either the 3rd Party Projections from Fantasy Data, the projections from the neural network models, or the scored fantasy points from players when “historical result” display is chosen.
  • Green – Site and/or slate specific parameters, such as player salary and position.
  • Yellow – Editable inputs for the neural network projection models. Changing the values in these columns should automatically update the values of the neural network projections.
  • White – General information, default stats, and custom stats.

 

Right clicking any highlighted players brings up a menu with the following options

  • Add – Checks the “Selected” column for that player, allowing that player to be used for building lineups.
  • Remove – Unchecks the “Selected” column for that player, preventing that player from being used for building lineups.
  • Clear Projections – Sets the projection values in the “Proj. Points” column to 0 for the highlighted players.
  • Use 3rd Party Projections – Set the “Proj. Points” projection equal to the projection values in the “3rdPartyProj” column for the highlighted players.
  • Use Neural Net Projections – Set the “Proj. Points” projection equal to the projection values in the “NeuralNetProj” column for the highlighted players.
  • Display History – Opens a player history window, showing historical stats for the selected player.
  • Display History vs. Opponent – Opens a player history window, showing historical stats for the selected player for games played against the current opponent.
  • Calculate custom stats – If custom stat columns are currently being displayed, clicking this option will calculate their results for all highlighted players.
  • Select All – Highlights all players.

Projections Tab - Game Information Window

The game information window serves two functions. First, it allows you to add or remove all players from specific games by clicking the check box in the “Selected” column. In addition, a variety of information about the games are displayed as well such as start times, weather, and Vegas odds.

Note that the columns for the projected team scores, spread, and over/under are colored yellow. Editing the values in these columns will automatically update the corresponding neural network inputs for all players in those games.  In addition, the projected team scores, spread, and over/under will update together when any one of them are changed so that they are all consistent.

 

Projections Tab - Column Settings

For both the projections/stats and game information windows, an “Edit Columns” button is shown in the top right. Clicking this button will bring up the column settings editor for that window. Here, you can browse for available stats and organize the layout of the windows with the stats you want. To add a new stat to a window, simply drag it from the “Available Columns” list to the “Selected Columns” list. You can also rearrange the order of the columns in the “Selected Columns” list according to your preference. Columns can also be removed from the windows by dragging them from the “Selected Columns” list back to the “Available Columns” list.

For the projections/stats window, you can scroll to the bottom of the “Available Columns” window to find editable custom stats that you can edit with your own SQL commands. There are 10 custom stats that can be saved with text outputs, and 10 that can be saved with numeric outputs. To bring up the custom stat editor, simply click one of the custom stats and then click the “edit custom stat” button.

Projections Tab - Custom Stat Editor

The custom stat editor allows you to enter define new stats by writing SQL commands to query the databases of statistics saved in Fantasy Analyst. For more information on this, watch the tutorial on custom stats, and look for SQL examples/tutorials online.

  • Settings - The settings box contains options for the current custom stat’s saved settings. In the text box under Stat Name, enter the name that you want to save for the new stat you’ve written. Clicking the Save button saves the current stat with the chosen name and the command written in the SQL Command window. Clicking the Cancel button exits the window without saving changes to the current custom stat.
  • SQL Options - In the SQL Options box, you can select a player for testing the result of the command written in the SQL Command window, and run the query by clicking the Execute SQL button.
  • SQL Command - In this window, enter the SQL command for the new custom stat you want to define.
  • Command Output - After clicking the Execute SQL button, the command will be executed for the selected player. The result is shown in this window.

Variance Tab - Overview

In the Variance tab, you can measure the variance of individual players/positions, and covariance between player/position pairs. After doing so, you can use the variance optimizer in the Lineups tab to factor variance and covariance in building lineups. The motivation for doing this is that increasing or decreasing the total variance of our lineups is a way we can control the randomness of how they score. For contest types such as large GPPs, it will often be beneficial to increase variance to add more randomness to raise the “ceiling” score. For contests such as 50/50s, reducing variance will typically be better in order to reduce the “floor” and maximize the probability of scoring above payout threshold.

 

When variance and covariance are calculated, non-zero values are only estimated for players who are in the same game, whether they are on the same team or opposing teams. There should be no covariance between players who are in different games since this implies that their scores should be independent of each other.

Variance and covariance are only calculated for players selected from the “Projections” window. If the calculation process is taking too long, removing players that you don’t think you’ll be using in your lineups is a good way to speed up the process (because covariance has to be calculated between every possible pair of players). Typically, having somewhere between 100-200 players selected allows the calculation to finish quickly.

The calculation process begins with taking the fantasy point history of all selected players over the chosen time frame. From there, the variance and covariance calculations are performed according to the chosen measurement type and the configured options. Once the calculations are finished, a covariance matrix is saved in the app that can be used for variance optimization in the “Lineups” tab. The individual results and data points for every player pair can be observed in the three windows shown as well.

For background reading on how variance and covariance are calculated and what they represent, please see the following links:

http://mathworld.wolfram.com/Variance.html

http://mathworld.wolfram.com/Covariance.html

Variance Tab - Settings and Options

 

Calculate Variance/Covariance – Clicking this button will begin calculating the variance and covariance estimates with the selected options and settings.

Date Selection – Select the start and end date for the history you want to use when measuring variance and covariance. The past year is used by default.

Measurement Type – If “By Player” is selected, variance will be calculated for individual players, and covariance will be calculated between pairs of specific players. This setting will typically be best to use when there are a larger number of games that have been played with players’ teammates and opponents. If “By Position” is selected, variance will be calculated for positions, and covariance will be calculated between pairs of positions (with separate values for pairs that are on the same team, and pairs that are on opposing teams). This option may be better to use for sports such as NFL, where only a limited number of games are played and the “By Player” option will not have enough data points between individual players.

Options – Several options here are available to configure depending on how you want to measure variance and covariance.

  • Minimum samples required – The number selected here will determine the minimum number of samples required to estimate the variance/covariance. If this number is not met, the variance/covariance is simply assumed to be zero. For example, let’s say we set this value to 30. If we try to measure the covariance between two players, and we only find 20 games where they have played together, then the covariance will be set to zero.
  • Exclude non-played games – Checking this box ensures that variance and covariance are only measured over games where the players actually participated. Unchecking this box will use all games over the selected time frame regardless of whether or not the players participated.
  • Exclude players below sample threshold – If this box is checked, any players that do not have a number of samples for their variance that is greater than the value in the “Minimum samples required” box will be removed from selection in the “Projections” tab. Checking this box essentially allows you to filter out players who have not had a long enough history.
  • Nearest PSD covariance matrix – Since the covariance between players is calculated in a pairwise manner, the final covariance matrix may not be positive semi-definite. As a result, you may possibly see things such as a negative total variance for your lineup. Checking this box will find the nearest valid covariance matrix that is positive semi-definite.

Variance Tab - Variance/Covariance Window

After clicking the “Calculate Variance/Covariance” button, this table will be populated with all variance and covariance entries calculated. The names, teams, and positions of both players are shown for each entry calculated, followed by the covariance, correlation, and number of samples used in the calculation. Here, the number of samples corresponds to the number of games available to calculate the covariance from. When the 1st and 2nd players shown in a row are the same, variance is shown (since taking the covariance of a variable with itself is equal to variance). For entries where the 1st and 2nd player are different, two entries are listed to include the case where the 1st and 2nd player are swapped.

Variance Tab - Selected Player Pair Points Window

If a row is selected from the “Variance/Covariance” window, the data points used in the covariance calculation will be plotted in in the "Selected Player Pair Points" window. When the 1st and 2nd player are the same, a histogram of fantasy points scored is shown. When they are different, a scatter plot is shown along with a linear fit. Examples screenshots of both cases are shown below:

In addition, the "Selected Player Pair Data" window provides a table showing the data points used for the plot and variance/covariance calculation. Fantasy points for both players are shown, along with the dates of the games those points were taken from.

Lineups Tab - Overview

After adjusting projections and making player selections from the Projections tab, the Lineups tab can now be used. The primary purpose of this tab is help construct lineups, but it also allows you to manage them across contests you've entered in for quick exporting. A few examples of tools and features of this tab are listed below:

  • Optimizers - Different optimizers are available that can be used to create the best lineups possible from your projections given the selected optimizer objective and constraints. These include a standard score optimizer, as well as a variance optimizer.
  • Constraints - Select a variety of different constraints for the optimizers to use when generating lineups, such as number of players to stack on a given team and minimum total salary.
  • Lineup Editor - Use the lineups editor to manually select the players you want in new lineups, or modify existing lineups. 
  • Contest Management - Import the contests you've entered in for the currently selected slate and site, assign your lineups to them, and then quickly export them for submission. 

Lineups Tab - Settings and Options

 

Generate Lineups Button – Clicking this button will generate lineups with the configured optimizer settings and options.

Optimizer – From here, you can choose the number of lineups to generate, and select from one of the three optimizers that are available for creating lineups. The first is a standard score optimizer, which will produce lineups that maximize projected or historical fantasy scores. The second is a variance optimizer, which creates lineups that maximize or minimize total lineup variance given a minimum projected fantasy points constraint. Using this optimizer requires generating variance estimates of players and covariance estimates player pairs by using the Variance tab. The third option is a weighted score/variance optimizer that uses both objectives of the previous optimizers, weighted according to some desired amount. Please read the Optimizers section for more information on these.

Score Optimizer Options – If the score optimizer is selected, you may choose here whether you want to maximize projected fantasy points or historical scored fantasy points when creating lineups. Maximizing projected points will be the objective when creating lineups to enter in real contests. Maximizing scored points can be selected after contests have completed, which may be used to determine what was the highest-scoring lineup that could have been created for those contests.

Variance Optimizer Options – If the variance optimizer is selected, you may choose here whether you want to maximize or minimize total lineup variance. In addition, it is often desireable when using the variance to set a minimumm points constraint at avalue that is not too far below the projected lineup scores using the standard score optimizer. This constraint effectively provides a way that you can "trade-off" projected points for more/less lineup variance.

Weight Options – If the "Weighted Score/Variance Optimizer" is chosen, you may choose here how you want to weigh maximizing projected lineup score vs. maximizing/minimizing lineup variance.

Generic Constraints– Two generic lineup constraints are available to set in this section. The first is a minimum lineup salary constraint. The second is a "minimum number of player differences between lineups" constraint. Setting this constraint to a value other than zero will ensure that there are at least that many player differences between all of the lineups you generate in a single optimization run. This can be useful to avoid making lineups that are too similar to each other.

Sport-Specific Constraints – This section will change depending on the sport to offer typical lineup constraints for that sport. For example, MLB features a variety of hitter stacks that can be specified for desired teams.

Save Button – Click this button to save all lineups and contests that are currently shown in the Lineups tab. If you do not save, switching to another date, slate, site, or sport may result in lineups or contests being lost.

Lineups Tab - Lineups Window

Lineups created from from the optimizers or lineup editor will appear in this window after they are generated. Some basic properties of the lineups are displayed, which include the lineup name, historical scored points, projected points, projected variance, the player names, and the total salary. The "ScoredPoints" column will only display historical scores after the games have completed, and the "ProjectedVariance" column will only show values after variance/covariance estimates have been generated from the Variance tab. In addition, the "LineupName" column can be edited to rename lineups as desired.

Highlighting one or more lineups (which can be performed by holding ctrl or shift and then left clicking), followed by right clicking the selection will bring up a menu with various options:

  • Delete - Removes the selected lineups
  • Edit - Sets the players from the selected lineup into the lineup editor.
  • Add to Contest - Adds the selected lineups into one or more contests from the Contests window. A menu will appear prompting you to choose the contests you wish to add the selected lineups into.
  • Replace in Contest - If you've imported your contest entries from a DraftKings or FanDuel CSV file and want to upload new lineup assignments back to those sites, you will need to use this option. Similarly to the "Add to Contest" option, a menu will prompt you for the contests you wish the replace the lineups in. However, rather than adding the lineups to the contests, the selected lineups can only replace existing lineups within the contests while leaving the "LineupName" column unchanged. This will allow the new lineups to be uploaded back to DraftKings or FanDuel without errors from the contest entry CSV file. 
  • Lineup Player Info - Opens a window for the selected lineup, showing basic information for the players in it. This includes information such as individual projections, teams, and the implied team/opponent scores fromt the Vegas odds. 
  • Lineup Player Covariance - If variance/covariance estimates have been generated from the Variance tab, clicking this option will create a window showing the variance/covariance information for the selected lineup. Entries on the diagonal show player variance, and off-diagonal entries show covariance between player pairs.
  • Ownership - After highlighting multiple lineups, choosing this option will produce a window showing player ownership across lineups, along with some basic information for the players shown. For example, if 10 lineups are highlighted and a particular player is in 4 of the lineups, that player's ownership will show as 40%.
  • Player Swap - This option allows you to swap one player from another across all lineups highlighted. A new window will appear, showing currently drafted players on the left, and available players to swap in on the right. Simply click on the player that you want to swap out from the left side, click on the player you want to swap in from the right side, and then click the "Swap" button. The swap will then be made across the highlighted lineups where possible. A prompt will then appear notifying you how many swaps were succesfully made and how many failed across the highlighted lineups.
  • Export to CSV - Exports the highlighted lineups to a CSV file with player IDs. This allows an alternate way to copy and paste lineups into your DraftKings and FanDuel contest entry CSV files without having to import them into Fantasy Analyst.
  • Select All - Highlights all lineups in the Lineups window.

Lineups Tab - Player Parameters Window

The Player Parameters window can be used to set player-specific constraints when building lineups. This includes whether to lock or exclude a player from lineups generated, and the maximum ownership for that player when generating multiple lineups. In addition, you may add individual players into the Lineup Editor to manually create lineups. Only players that were selected from the Projections tab will be displayed in the Player Parameters window.

Right clicking the Player Parameters window opens a menu allowing you to set options for multiple highlighted players. For example, let's say that we want to limit the maximum ownership of all players to 75%. To do this, simply right click the Player Parameters window, choose "Select All", right click again, and choose "Set Ownership %". A window will appear prompting us for the desired maximum ownership percentage. If we enter 75% and click OK, we'll now see that all players will have a MaxOwnership% value of 75.

Lineups Tab - Lineup Editor Window

The Lineup Editor window can be used to manually create new lineups or adjust existing ones. Players can be added into the editor by clicking the + button in the "Add" column of the Player Parameters window, or right clicking an existing lineup and selecting "Edit" from the menu. To remove a player from the editor, simply click the X button in the "Delete" column.

If there are one or more open position slots in the editor, you can click the "Optimize Remaining" button to automatically fill them. This will use the selected optimizer with the current settings to select the remaining players while keeping any players that are already in the editor.

Once all positions in the editor are filled, you can click the "Add Lineup" button to generate a new lineup with your selected players in the Lineups window.

Lineups Tab - Contests Window

The Contests window allows you to manage lineups from your DraftKings or FanDuel contest entries, easily swap in new ones you create through Fantasy Analyst, and then quickly export them. You can also create contests to simply store lineups, which may be useful when trying to compare results from using different optimizers or constraints. Clicking a contest in the Contests window will display the lineups assigned to that contest in the Selected Contest Lineups window below it as shown in the following figures:

Three buttons are shown in the top of the Contests window:

New - This button creates a new, empty contest. Lineups can be added to the new contest by right clicking them and choosing "Add to Contest".

Import - If you've saved a contest entry CSV file from DraftKings or FanDuel for the current slate, you may import it into the Contests window by clicking this button. The contests and the lineups assigned to them will then appear. If there were any errors during the import, a warnng message will appear.

Export - Once you're ready to upload your new lineups back to DraftKings or FanDuel, click this button to open a lineup export window. This will produce a table with all contests and assigned lineups, as shown in the example figure below. You can copy the entire table by right clicking anywhere on the table and selecting "Copy". After doing this, simply paste the new contest-lineup assignments back to the original DraftKings or FanDuel contest entry CSV file. Finally, upload the updated file back to DraftKings or FanDuel and your new lineups should appear.

Projection Accuracy Tab - Overview

Through the Projection Accuracy tab, you can easily measure the historical accuracies of projections sets you have saved. In addition, you can compare different projection sets with each other over the same sets of players and assumptions. It is recommended that you use this tab regularly in order to identify the best projection sources to use when generating lineups.

Projection Accuracy Tab - Settings and Options

 

Plot – Clicking this button will calculate the projection set accuracy given the configured settings and options. Once the data has been loaded, the "Projected/Scored Points" window will show the projections and residuals for each player-game. The residuals will also be plotted in both a histogram and scatter plot on the right side of the window. Keep in mind that if a large number of projections are being selected, it may take a minute or so before the results are displayed.

Projection Set Selection – From this list box, select the projection set that you want to measure the historical accuracy of. Projection sets will only be shown for those that were saved for the currently configured site and sport.

Comparison Set Selection – If you want to compare different projection sets against each other only over matching player-game entries, you can select one or more comparison sets from this list box. The comparison sets selected will require that the accuracy measurement for the primary projection set only consider projections that exist where matching player-game projections also exist for the comparison sets. For example, let's say I want to compare the "3rd Party" projections in the app against a new set I've only saved for yesterday called "Projection Set X". To do this, I can first select both "3rd Party" and "Projection Set X" as comparison sets (by holding the ctrl key and clicking both). I can then individually choose "3rd Party" and "Projection Set X" as the primary sets and click the Plot button. This will ensure that the measurement is using projections for the same player-game entries in both cases.

Date Selection – Choose the date range over which you want to measure the accuracy of the selected projection set.

Positions – If you only want to measure projection accuracies over specific positions, you can configure this by using the check boxes for the postions listed.

Options – Two additional options for filtering out projections are available here:

  • Exclude non-played: Enabling this option will exclude any projections from the accuracy measurement where the player did not participate in the game the projection was made for. This is enabled by default.
  • Exclude zero projections: Enabling this option will exclude any projections from the accuracy measurement where the projected value was set to zero.

Projection Accuracy Tab - Projected/Scored Points Window

After clicking the "Plot" button, all projection entries used in measuring the accuracy for the selected projection set will be displayed in this window. The projected points, historical scored points, and residual (error of the projection) are displayed towards the right. Some basic information for each entry is shown as well such as the player name and date of the projection.

Projection Accuracy Tab - Residual Plots

The results of the projection accuracy measurements are illustrated in two plots. The first is a histogram of projection error. This plot provides a good visualization of the general accuracy, along with how often larger errors occur. The second is a scatter plot with projected points on the X-axis, and the projection error on the Y-axis. This plot gives a better illustration of how the error varies between low projections and high projections.

 Several key pieces of information summarizing the accuracy measurements are shown in the top right corner of the histogram plot. These include the number of projections used in the measurement, the root-mean-squared error, and the R-squared value. Greater accuracy typically corresponds to a lower root-mean-squared error, and higher R-squared value.

Entry History Tab - Overview

The Entry History tab can be used to import and view your contest results from DraftKings, FanDuel, and Yahoo. From here, you can track your win/loss history across different sites and sports.

Entry History Tab - Settings and Options

 

Plot Button – Click this button to display your winnings and contest history with the currently selected settings and options.

X Axis – Select the format of the X-axis you want to use for the winnings history plot. You can choose to plot the contests on an increasing number scale, or according to date.

Y Axis – Select the format of the Y-axis you want to use for the winnings history plot. You can plot the winnings in dollar amounts, or in terms buy-ins.

Date Selection – Choose the start and end dates that you want to display the winnings and contest history over.

Site – Choose the specific DFS sites that you want to plot results for, or use the "Select All" option to plot all site results.

Site – Choose the specific sports that you want to plot results for, or use the "Select All" option to plot all sport results.

Import History Button – Click this button to import an entry history CSV file from DraftKings, FanDuel, or Yahoo. The correct site will automatically be determined from the format of the CSV file.

Entry History Tab - Winnings and Contest Entry Windows

Two windows are used to display the contest entry history after clicking the "Plot" button. On the left side, a graph showing cumulative wins/losses is shown. In the top right corner of this plot, both the total winings and the average return on investment (ROI) are provided as well. On the right side, information about the individual contest entries is displayed in a table. Contest entries that resulted in a loss are colored in red, and those that resulted in a win are colored green.

Neural Network Models - Overview

The majority of DFS projection sources do not provide information on how their projections are created or their historical accuracy. As expected, this is often because they are not generated in a rigorous manner and have poor accuracy. With Fantasy Analyst, I wanted to provide projection models based off of modern regression techniques and be transparent about how they were created and how accurate the projections themselves have been historically. To do this, I've implemented pre-trained neural network regression models for predicting fantasy points. These models were trained using MATLAB and then implemented in Fantasy Analyst. Seperate models are trained for each DFS site and sport.

In this section of the guide, detailed information is provided regarding how the models were trained, the inputs they use, and their accuracies. To determine the accuracy of these models, the root-mean-square errors and R^2 values are measured over a test period that is seperate from the training data. For comparison, the same metrics are also provided for the 3rd party projections from FantasyData, and projections generated by taking a simple average of past fantasy point scores. Lower root-mean-square errors and higher R^2 values indicate better performance. The model parameters and inputs were chosen after experimenting with a number of different combinations and choosing what gave the best performance with a manageable number of inputs.

To use these models in the app, simply click on the "Generate Neural Network Projections" button from the Projections tab after you have selected your desired site, sport, date and slate. Doing this will automatically generate the projections for all selected players. These projections will appear in the "NeuralNetProj" column if all required inputs were available. You can then use these projections for building lineups by highlighting the players of interest, right clicking, and then choosing "Use Neural Net Projections". All yellow columns in the Projections tab are editable inputs for the neural network models. You can change these as you wish and the neural network projections will automatically update after doing so.

MLB Neural Network Model

Training data period: 4/1/2017-7/31/2017

Test data period: 8/1/2017-9/31/2017

For MLB, seperate neural network models are used for starting pitchers and hitters. 

Projected team and opponent scores are determined from the spread and over/under. For example, the projected score for the home team would be calculates as (OverUnder-Spread)/2.

MLB Hitter Model

Inputs: Average fantasy points over past 50 games, projected team score, projected opponent score, team moneyline, opponent moneyline, batting order. 

Root-Mean-Square Error (RMSE) DraftKings FanDuel Yahoo
Fantasy Analyst 7.3244 9.8951 6.2496
3rd Party (FantasyData) 7.5253 10.1626 6.4216

Average Fantasy Points (past 50 games)

7.4206 10.0213 6.3280

 

R^2 Value DraftKings FanDuel Yahoo
Fantasy Analyst 0.0279 0.0291 0.0288
3rd Party (FantasyData) -0.0261 -0.0241 -0.0254

Average Fantasy Points (past 50 games)

0.0022 0.0041 0.0042

 

MLB Starting Pitcher Model

Inputs: Average fantasy points over past 50 games, average strikeouts per 9 innings over past 50 games, projected team score, projected opponent score, team moneyline, opponent moneyline, batting order. 

Root-Mean-Square Error (RMSE) DraftKings FanDuel Yahoo
Fantasy Analyst 10.9320 16.1369 12.0106
3rd Party (FantasyData) 11.0670 16.2875 12.1596

Average Fantasy Points (past 50 games)

11.1455 16.4337 12.2370

 

R^2 Value DraftKings FanDuel Yahoo
Fantasy Analyst 0.1170 0.1114 0.1142
3rd Party (FantasyData) 0.0935 0.0932 0.0907

Average Fantasy Points (past 50 games)

0.0822 0.0785 0.0805

NFL Neural Network Model

Training data period: 10/1/2017-11/27/2017

Test data period: 12/3/2017-12/25/2017

For NFL, seperate neural network models are used for players and defenses. 

Projected team and opponent scores are determined from the spread and over/under. For example, the projected score for the home team would be calculated as (OverUnder-Spread)/2.

NFL Player Model

Inputs: Average fantasy points over past 20 games, projected team score, projected opponent score, is player starting, average fantasy points allowed by opposing team. 

Root-Mean-Square Error (RMSE) DraftKings FanDuel Yahoo
Fantasy Analyst 5.9385 5.1099 5.1556
3rd Party (FantasyData) 5.7613 4.9412 4.9606

Average Fantasy Points (past 20 games)

6.0080 5.1595 5.2112

 

R^2 Value DraftKings FanDuel Yahoo
Fantasy Analyst 0.4534 0.4570 0.4653
3rd Party (FantasyData) 0.4855 0.4923 0.5050

Average Fantasy Points (past 20 games)

0.4402 0.4461 0.4537

 

NFL Defense Model

Inputs: Average fantasy points over past 20 games, projected team score, projected opponent score, average fantasy points allowed by opposing team. 

Root-Mean-Square Error (RMSE) DraftKings FanDuel Yahoo
Fantasy Analyst 5.6883 5.8585 5.8585
3rd Party (FantasyData) 6.2030 6.5111 6.5111

Average Fantasy Points (past 20 games)

5.6498 6.2880 6.2880

 

R^2 Value DraftKings FanDuel Yahoo
Fantasy Analyst 0.0858 0.2123 0.2123
3rd Party (FantasyData) 0.1172 0.1156 0.1156

Average Fantasy Points (past 20 games)

-0.0679 0.0649 0.0649

NBA Neural Network Model

Training data period: 10/17/2017-11/30/2017

Test data period: 12/1/2017-12/31/2017

For NBA, data is filtered to only include player-games where the player did not get injured.

Projected team and opponent scores are determined from the spread and over/under. For example, the projected score for the home team would be calculated as (OverUnder-Spread)/2.

Inputs: Is player starting, projected team score, projected opponent score, average minutes over past 20 games and past 5 games, average fantasy points per minute over past 20 and past 5 games. 

Root-Mean-Square Error (RMSE) DraftKings FanDuel Yahoo
Fantasy Analyst 9.0647 9.1700 9.1962
3rd Party (FantasyData) 9.2865 9.3979 9.4015

Average Fantasy Points (past 20 games)

9.2789 9.4011 9.3999

 

R^2 Value DraftKings FanDuel Yahoo
Fantasy Analyst 0.5824 0.5611 0.5581
3rd Party (FantasyData) 0.5617 0.5390 0.5382

Average Fantasy Points (past 20 games)

0.5624 0.5387 0.5383