Its very similar to how you would brute force a solution with (eval func)
"1^:_  on rows of  input ; score

after each iteration, sort on score, keep some cutoff portion (say 20), and 
generate some new inputs based on qualities of top scoring ones (say 10 per 
each top 20 scoring one).  Can memoize the eval func or just eval score only if 
score field is a: (input just added)

stops when top 20 stay in top 20 (converge) even after 200 new inputs added.  
instead of ^:_ , you can do ^:10000 or some other large number, because there's 
no guarantee of a solution even with ^:_ and randomness, and so you can want to 
reiterate even after a solution.


Works best if your scoring function can work like the mastermind game. 1. There 
is something good about x number of your inputs, and preferably 2. x of your 
inputs are in the exact right spot, or something is really good about them.




----- Original Message -----
From: Devon McCormick <[email protected]>
To: J-programming forum <[email protected]>
Sent: Thursday, December 17, 2015 3:52 PM
Subject: [Jprogramming] Genetic algorithms?

Has anyone done work in J on genetic algorithms?   I'm thinking of coding
up something along these lines as I don't find any relevant hits for this
on the J wiki.

-- 

Devon McCormick, CFA

Quantitative Consultant
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to