Rory B

Results 7 comments of Rory B

You can do something like this if you're running Python 3.10: ``` match slatesize: case 3: #stack defined here case (10|13|14|15): # stack defined here case _: #default stack defined...

I had to add a for_teams clause. ``` opto.add_stack(TeamStack(5, for_teams=teams,max_exposure=.35, for_positions=['C', 'SS', 'OF', '1B', '2B', '3B'])) opto.add_stack(TeamStack(2, max_exposure=.5, for_positions=['C', 'SS', 'OF', '1B', '2B', '3B'])) opto.add_stack(TeamStack(1, for_positions=['C', 'SS', 'OF', '1B', '2B',...

``` teams = stacks['Team'].tolist() cap = {teams[i]: stacks['Percent'].tolist()[i] for i in range(len(stacks['Team'].tolist()))} #turn list of teams and percentages into dictionary runs = sum(stacks['Entries']) #calculate total number of lineups needed ```...

> What is the run part doing? runs is just a variable for how many lineups I want.

> I think im following you here @norraist , but im a noob when it comes to python coding. Can you show me one example from a past slate? It's...

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. ` Name...

Came looking for this exact feature. It would be very useful!