if n> Cp, then fi = n; else fi = 0
(4.28)
where n is the number of fitness cases correctly evaluated, and
Cp is the number of fitness cases of the class with more members (predominant class).
For this problem, chromosomes composed of three genes with an h = 8 and sub-ETs linked by addition were used. The program below was discovered using a small population of 50 individuals:
-d1/=*>!+d6d0d4d6d5d2d6d4d6
(4.29a)
It has a fitness of 340 evaluated against the training set of 350 fitness cases and a fitness of 173 evaluated against the testing set of 174 examples. This corresponds to a testing set classification error (the percent of incorrectly classified examples) of 0.575% and a classification accuracy of 97.143%.
Note that for the expression of this chromosome to be complete the 0/1 rounding threshold
Rt = 0 must be taken into account. With the software APS we can automatically convert the model
(4.29) above into a fully expressed C++ function:
double APSCfunction(double d[])
{double dblTemp = 0;
dblTemp += (d[3]>(((d[4]>=d[1]?d[4]:d[1])+ (d[1]==d[7]?d[1]:d[7]))==(d[8]+d[0])?((d[4]>=d[1]?d[4]:d[1])+ (d[1]==d[7]?d[1]:d[7])):(d[8]+d[0]))?d[3]:(((d[4]>=d[1]?d[4]:d[1])+ (d[1]==d[7]?d[1]:d[7]))==(d[8]+d[0])?((d[4]>=d[1]?d[4]:d[1])+ (d[1]==d[7]?d[1]:d[7])):(d[8]+d[0])));
dblTemp += ((d[5]+d[5])!=(((d[7]/d[3])>d[2]?(d[7]/d[3]):d[2])!= (d[2]>d[6]?d[2]:d[6])?((d[7]/d[3])>d[2]? (d[7]/d[3]):d[2]):(d[2]>d[6]?d[2]:d[6]))? (d[5]+d[5]):(((d[7]/d[3])>d[2]?(d[7]/d[3]):d[2])!= (d[2]>d[6]?d[2]:d[6])?((d[7]/d[3])>d[2]? (d[7]/d[3]):d[2]):(d[2]>d[6]?d[2]:d[6])));
dblTemp += (d[1]-(((d[0]>d[4]?d[0]:d[4])==(d[6]!=d[5]? d[6]:d[5])?(d[0]>d[4]?d[0]:d[4]):(d[6]!=d[5]? d[6]:d[5]))/((d[2]+d[6])*d[6])));
return (dblTemp>= 0 ? 1 : 0);
}
(4.29b)
In this form, the model seems really complicated, but its parsing shows that its sub-ETs are really simple
(Figure 4.13). Note that all the attributes seem to be relevant to an accurate diagnosis of breast cancer. Indeed, one of the advantages of the models evolved by GEP is that they allow knowledge extraction because they are not only accessible but also easy to interpret.
Figure 4.13. Model evolved by GEP to diagnose breast cancer.
a) The three-genic chromosome encoding sub-ETs linked by addition.
b) The sub-ETs codified by each gene. Note that the expression of this chromosome is only complete after including the rounding threshold which in this case is equal to zero.