Skip to content

Commit

Permalink
Fixing wrong parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
apanichella committed Jul 19, 2019
1 parent a0344e1 commit dc702f6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion metaheuristics.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ source(paste(main_path, "/fitness_functions.R", sep=""))
run_metaheurisic<-function(name, lower_bounds=c(), upper_bounds=c(), n_iterations, pop_size){
if (name == "GA"){
print("Running Genetic Algorithms")
res<-ga(type = "real-valued", fitness = fitness_LDA, lower=lower_bounds, upper=upper_bounds, pmutation=1/4, maxiter=nGen, run=n_iterations, popSize=pop_size, mutation=gareal_raMutation, crossover = gareal_blxCrossover)
res<-ga(type = "real-valued", fitness = fitness_LDA, lower=lower_bounds, upper=upper_bounds, pmutation=1/4, maxiter=n_iterations, run=n_iterations, popSize=pop_size, mutation=gareal_raMutation, crossover = gareal_blxCrossover)
best <- summary(res)
return(best$solution)
} else if (name == "DE") {
Expand Down

0 comments on commit dc702f6

Please sign in to comment.