DimaKudosh / pydfs-lineup-optimizer

Daily Fantasy Sports lineup optimzer for all popular daily fantasy sports sites
MIT License
423 stars 157 forks source link

Exclude Position from Team Exposure Calculations #352

Open norraist opened 2 years ago

norraist commented 2 years ago

From the documentation: "The team counted as used in the lineup if at least one player from it is in the lineup."

For baseball, I want to exclude the SP from this calculation. I'm far more concerned with the number of stacks I have on offense and the SP doesn't factor into that requirement at all.

Can we have a way to exclude a position from the team exposure calculation?

norraist commented 2 years ago

So there's a work around to this issue. Set the SPs to be their own "team". This tricks the solver into not counting the pitchers in the exposures.

`<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40">

Name + ID | Name | ID | Roster Position | Salary | Game Info | TeamAbbrev | AvgPointsPerGame -- | -- | -- | -- | -- | -- | -- | -- Charlie Morton (202429) | Charlie Morton | 202429 | SP | 7800 | ATLSP@MIL 03/23/2022 11:21AM ET | ATLSP | 28.98 Jorge Soler (658226) | Jorge Soler | 658226 | OF | 3300 | ATL@MIL 03/23/2022 11:21AM ET | ATL | 16.59

`