Retinal vessel segmentation is a prerequisite for the analysis of vessel parameters such as tortuosity, variation of the vessel width along the vessel and the ratio between the venous and arterial vessel width. This analysis can provide indicators for the presence of a wide range of diseases. Different types of approaches have been proposed to segment the retinal vasculature and two important groups are vessel tracking and pixel processing based methods. An advantage of tracking based methods is the guaranteed connectedness of vessel segments, in pixel processing based methods connectedness is not guaranteed. In this work an automated vessel linking framework is presented. The framework links together separate pieces of the retinal vasculature into a connected vascular tree. To determine which vessel sections should be linked together the use of a supervised cost function is proposed. Evaluation is performed on the vessel centerlines. The results show that the vessel linking framework outperforms other automated vessel linking methods especially for the narrowest vessels.