|more useful options|
Re: Re: Re (tilly) 1: Baseball line up (best rotation)by aijin (Monk)
|on May 17, 2001 at 22:39 UTC||Need Help??|
Just to supplement Masem's reply...
First, you might consider doing a crossover in addition to a mutation to ensure that you properly explore the line-up space. You'll need to do a partially matched crossover (PMX) to ensure that you don't duplicate the team members. You could do a mutation as suggested by Masem either on each lineup or on each member of a lineup 1-5% of the time.
Secondly you could experiment with various types of selection algorithms for determining who breeds and who dies. Masem suggested the Percentage model, but there's also the Roulette and Tournament models.
Third, it would be really neat to take your top lineup from one run and stick it into a new run of the GA to see how it fares.
Check out Genetic Algorithms with Perl for more guidance and inspiration.
Addendum: I just realized the page didn't actually link to the code.