diff --git a/README.md b/README.md index cf514c5..56511eb 100644 --- a/README.md +++ b/README.md @@ -4,15 +4,15 @@ Yet another Push-based genetic programming system in Clojure. ## Usage -To run PushGP on the default genetic programming problem -from a REPL, load propel.core into your REPL (i.e. `lein repl`), -and run `(-main)`. +To run PushGP from a REPL, load propel.core into your REPL (i.e. `lein repl`), +and run `-main` with arguments including, first, the problem name, for example: +`(-main 'simple-regression)` or `(-main 'simple-regression :population-size 100)`. -To run PushGP on the default genetic programming problem from -command line, execute `lein run`. Command-line arguments may -be provided to override the defaults specified in `-main`, for -example, `lein run :population-size 100`. You can use something -like `lein run | tee outfile` to send output both to the terminal +To run PushGP on the genetic programming problem p from the +command line, execute `lein run p`. For example `lein run simple-regression`. Additional command-line arguments may +be provided to override the default key/value pairs specified in `-main`, for +example, `lein run simple-regression :population-size 100`. You can use something +like `lein run simple-regression | tee outfile` to send output both to the terminal and to `outfile`. ## CLJS Usage diff --git a/src/propeller/core.cljc b/src/propeller/core.cljc index 720184f..d24adb8 100755 --- a/src/propeller/core.cljc +++ b/src/propeller/core.cljc @@ -33,6 +33,7 @@ :variation {:umad 0.5 :crossover 0.5} :elitism false} (apply hash-map - (map read-string (rest args)))) + (map #(if (string? %) (read-string %) %) + (rest args)))) [:error-function] identity)))