The algorithm presented in the previous chapter is profiled for automatic analysis of the width of vessels. The analysis is made for each pixel of the image, with an accuracy described by the relation (1) (for the angular values with a resolution of one degree). The use of this automated method of analysis of data obtained in the image Lk will be suggested below.
Assuming that the radius of the optic disc is known (referred to as r), we can designate a circular band whose diameter is in the range of 2r to 3r (Figure

). This range has been proposed in IVAN software [
8] and is commonly used in the calculation of changes in diameter of arteries and veins, which enables to assess the coexistence of those changes with the progression of vascular disease.
The presented analysis applies to:
fully automatic measurement without any operator intervention,
measurement of the number of vessels in a declared area further on denoted as z,
the average angular value for individual objects in the image L
k – further on denoted as
sr,
standard deviation of mean angular values in the image L
k - further on denoted as
STD,
calculation of the maximum value of the angle in the image L
k - further on denoted as
max,
calculation of the percentage of the ratio of vessels surface area in relation to the measured area (calculated as the ratio of the total number of pixels that make up the vessels in the measured area to the total number of pixels of the area) – denoted as ps,
designation of histogram of pixel inclination of objects.
The results obtained for the test group (for healthy people and those with arterial hypertension) are given in Table

.
| Table 1Fragment of results of automated measurement of morphometric parameters of vessels |
Analyzing these results, we can, for example, read them for measurement no. 4. This is a patient without hypertension for whom 11 separated objects have been detected automatically in the area 2r to 3r. Their average angle of inclination with respect to the axis was 16.1°. In addition, most pixels of objects were found for a 13° angle. All the detected pixels of objects constituted 6.6% of the total measured area (2r to 3r).
In terms of diagnosis of hypertension, there is another interesting histogram which relates to changes in the values of the angle ϕ. The histogram presented in Figure

shows that the maximum is for the angle ϕ=6°, for which there were 240 pixels in total making up the vessels. Sloping nature of the envelope of the histogram is evidence of a small number of pixels with the value of the angle ϕ much exceeding 40°. It means that the vessels radiate from the center of the optic disc. Any angular error of unevenness is in the range of 10 to 40° and affects less than half of the pixels.
A group of 52 patients (including 40 healthy and 12 hypertensive ones) was divided in equal proportions into learning, validation and test group). Then, the cross-validation method was used, with particular reference to the ratio between the decision classes (stratified cross-validation). A classifier in the form of a decision tree was implemented, assuming five attributes: the angle for the maximum number of pixels - ϕmax, standard deviation of the angle average ϕSTD, the average value of the angle - ϕsr, the number of vessels in a declared area – z, and the percentage of the ratio of vessels surface area to the measured area - ps. It was recognized that these attributes are equally privileged. On this basis, six decision trees were constructed; five trees for each of the attributes occurring independently and one for all of them together.
In all cases, a non-parametrical algorithm CART (Classification and Regression Trees) creating binary trees is used as the method for their induction. An increase in the nodes purity has been used as the criterion for assessing the quality of CART divisions. The Gini index has been used as the measure of nodes impurity. Because of a small number of cases, the tree creation was not limited by a minimum number of vectors in a node. Then, to prevent excessive fitting to the data, the created tree is pruned to the maximum extent. At the first stage, the resubstitution error for various subsets of the original tree has been calculated. Then the cross-validation error for these sub-trees has been calculated. The cut-off value was set at the minimum cost (misclassification error) plus one standard error. The best level has been determined as the smallest tree below this cut-off. After pruning trees (to avoid over-fitting), the following results were obtained (true positive-TP, true negative - TN, false negative – FN and false positive-FP), i.e.:
For each of six trees created, the resultant values of accuracy have been calculated, ACC

=

(TP

+

TN)/(TP

+

TN

+

FP

+

FN), i.e.: z- 0.94, ϕ
SR- 0.92, ϕ
STD- 0.94, ϕ
max- 0.96, p
s- 0.94 and z, ϕ
SR, ϕ
STD, ϕ
max, p
s- 0.96. The ACC value was minimal for two pruned trees created on the basis of feature ϕ
max only and of all z, ϕ
SR, ϕ
STD, ϕ
max and p
s. The tree, whose construction requires only one feature ϕ
max, was chosen from these two decision trees. Therefore, this tree was classified as the best. In addition, after pruning, the tree constructed for z, ϕ
SR, ϕ
STD, ϕ
max, p
s has only one node with the same attribute ϕ
max – which confirms its proper selection (Figure

). For this tree (created on the basis of the attribute ϕ
max), the following indicators are obtained: sensitivity or true positive rate TPR

=

TP/(TP

+

FN)

=

0.83, false positive rate FPR

=

FP/(FP

+

TN)

=

0, accuracy ACC

=

(TP

+

TN)/(TP

+

TN

+

FP

+

FN)

=

0.96, specificity SPC

=

TN/(FP

+

TN)

=

1, positive predictive value PPV

=

TP/(TP

+

FP)

=

1, negative predictive value NPV

=

TN/(TN

+

FN) =0.95, false discovery rate FDR

=

FP/(FP

+

TP)

=

0. Therefore, when analyzing the results obtained from the created decision tree, the average value of ϕ
max is 6.8±5.1° for patients without hypertension and 24.3±3° for patients with hypertension. While treating the two cases, FN

=

2, as thick errors, the result obtained for all patients with hypertension is 21.6±7.6°. Calculations were made for the cut off marked from a decision tree whose ϕ
max
=

18.5°. With a confidence level of 0.001, the critical value of Student-t distribution for a group of healthy subjects (39 degrees of freedom) is 3.55, for patients with hypertension (11 degrees of freedom) - 4.43. For the latter group, the bottom end of the confidence interval is 21.6 - 4.43 * 7.6/√ 12

=

14.5, whereas the top one is 6.8 - 3.55 * 5.1/√ 40

=

9.66. Both bands have no elements in common - they are well separated. Thus, it can be said, with probability equal to 99.9%, that the value of the angle ϕ
max is reliable in the assessment of hypertension. However, there are two things which should be borne in mind, namely a relatively small number of subjects with hypertension and a number of cases of false positives equal to 2, which constitutes (FN/TP * 100) 16.6% error with respect to all patients.
Comparison with other methods
The presented algorithm is designed to collect statistical information about the number and tortuosity of vessels in the analyzed area of the eye. The value of the angle ϕ obtained from the image is, by definition, the measure of tortuosity and number of vessels. According to the information given in the introduction, the aim of the algorithm is not the most accurate segmentation of vessels. In general, objects (vessels) visible in the picture L
w or L
k (Figure


9, Figure

) do not have to be continuous. Furthermore, the algorithm does not have to segment all the vessels. Therefore, high accuracy is not required. The only common feature is related to the fact that the ratio of thickness of vessels must be preserved. The reason is that each pixel of an object (vessel) affects the shape of the histogram (Figure

) and thus the value ϕ
max.
The results of the presented algorithm were compared with the results obtained with DRIVE database [
30]. The assessment of quality of segmentation of vessels should be distinguished from the evaluation of the adopted statistical methods. Minor differences were obtained in the detected level of details of vessels in favor of the method described in paper [
30]. Underestimation and lack of vessels continuity were the main reasons for these differences. For 20 verified cases, the underestimation was less than 15% of the total area of all objects. It should be noted that despite receiving seemingly worse results of segmentation of vessels, the method described above has not been profiled for this purpose. This method enables to obtain directly the measurement results of tortuosity and percentage of vessels in the analyzed area. Therefore, in contrast to the methods described in the introduction [12–21], there is no need to perform additional analyzes like zooming vessels with a curve [
12,
16] or using patterns of tortuosity [
15] etc. This is the biggest advantage of the presented algorithm over other methods described in all the publications [12–21]. An additional advantage of this algorithm is negligible sensitivity to change of image acquisition parameters - for different operators, different camera settings and different patient settings. This is due to the characteristics of the algorithm: automatically corrected unevenness of lighting and acceptance of lack of vessels continuity.
Comparing the obtained results with those of other authors, a similar global approach in the fractal analysis can be found. The fractal dimension shown in papers [
31,
32] allows for a group division into healthy subjects and those with hypertension. In paper [
31], the value, i.e. fractal dimension, is fixed at 1.437 with a standard deviation of 0.025. However, this method is semi-automatic. Paper [
33], on the other hand, presents an interesting method based on nonlinear orthogonal projection approach. This method uses the afore-mentioned DRIVE database. The authors have obtained 96.1% accuracy. The results are similar to those obtained in this paper (96% accuracy). However, they were obtained with a slightly different method. The differences consist in the fact that the algorithm presented in paper [
31] is not fully automatic (the differences are thus related to the segmentation method). The algorithm presented in paper [
33] does not apply directly to the detection of patients with hypertension. The level of accuracy at 96.1% indicated by the authors concerns the quality of segmentation of vessels. It is not a measure of the quality of separation of patients with hypertension from healthy subjects. Yet in paper [
32] a global fractal analysis applies only to chronic kidney disease. The results in the diagnosis of this condition are at 95%. Therefore, a comparison with the use of the fractal dimension was carried out for the images obtained in this study. For this purpose, Fracllac software (Local Connected Fractal Dimension Analysis function) was used, which is, for example, described in paper [
24]. However, using only Fracllac software, no correlation between hypertension and the fractal dimension in the angiographic image was obtained. The reason was a major influence of lighting unevenness and artifacts visible in the image, which were not filtered. Whereas using the image pre-processing suggested in this paper, the accuracy was 81%. However, this result was obtained for the hybrid method which combines a filtration method suggested in this paper with the fractal analysis made with Fracllac software.
The algorithm described here can also be divided into functions related to each analysis phase. Then it will be possible to make a comparison with other GUI profiled to Matlab. Such an example is Fraclab [
25] which is a set of functions extending the functionality of Matlab. It has common features with the presented algorithm only in terms of filtration. The main way of calculating the matrices L
ma and L
θ, and on their basis L
w, which is presented above (4), is not available there. Of course the angle of the mask h
2 can be changed manually, and then this manual method is similar to the one presented above.