Skip to content

Commit 8906bf4

Browse files
author
Maximilian Reißmann
committed
add comment docu
1 parent 79db8ec commit 8906bf4

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

docs/src/api-reference.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -292,14 +292,14 @@ The package implements several genetic operators. Here the can be adjusted in ad
292292
```julia
293293
using GeneExpressionProgramming
294294

295-
GENE_COMMON_PROBS["mutation_prob"] = 1.0 # Probability for a chromosome of facing a mutation
296-
GENE_COMMON_PROBS["mutation_rate"] = 0.1 # Proportion of the gene beeing changed
295+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["mutation_prob"] = 1.0 # Probability for a chromosome of facing a mutation
296+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["mutation_rate"] = 0.1 # Proportion of the gene beeing changed
297297

298298

299-
GENE_COMMON_PROBS["inversion_prob"] = 0.1 # Setting the prob. for the operation to take place
300-
GENE_COMMON_PROBS["reverse_insertion_tail"] = 0.1 # Setting IS
301-
GENE_COMMON_PROBS["reverse_insertion"] = 0.1 # Setting RIS
302-
GENE_COMMON_PROBS["gene_transposition"] = 0.0 # Setting Transposition
299+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["inversion_prob"] = 0.1 # Setting the prob. for the operation to take place
300+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["reverse_insertion_tail"] = 0.1 # Setting IS
301+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["reverse_insertion"] = 0.1 # Setting RIS
302+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["gene_transposition"] = 0.0 # Setting Transposition
303303

304304

305305
```
@@ -315,8 +315,8 @@ Available crossover operators: Similar to the gene
315315
```julia
316316
using GeneExpressionProgramming
317317

318-
GENE_COMMON_PROBS["one_point_cross_over_prob"] = 0.5 # Setting the one-point crossover
319-
GENE_COMMON_PROBS["two_point_cross_over_prob"] = 0.3 # Setting the two-point crossover
318+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["one_point_cross_over_prob"] = 0.5 # Setting the one-point crossover
319+
GeneExpressionProgramming.RegressionWrapper.GENE_COMMON_PROBS["two_point_cross_over_prob"] = 0.3 # Setting the two-point crossover
320320
```
321321

322322
## Function Sets

docs/src/examples/physical-dimensions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,8 +262,8 @@ println("Analysis plot saved as 'physical_dimensionality_analysis.png'")
262262
println("=== Detailed Comparison with True Relationship ===")
263263

264264
# Calculate predictions using the true relationship
265-
true_predictions_train = -x_train[:, 1] .* x_train[:, 2] .* x_train[:, 3] .* x_train[:, 4]
266-
true_predictions_test = -x_test[:, 1] .* x_test[:, 2] .* x_test[:, 3] .* x_test[:, 4]
265+
true_predictions_train = -x_train[:, 1] .* x_train[:, 2] .* x_train[:, 3] ./ x_train[:, 4]
266+
true_predictions_test = -x_test[:, 1] .* x_test[:, 2] .* x_test[:, 3] ./ x_test[:, 4]
267267

268268
# Compare evolved vs true relationship
269269
comparison_plot = plot(layout=(1,2), size=(1000, 400))

0 commit comments

Comments
 (0)