def __update_clusters(self):
clusters = [[] for i in range(len(self.__medians))]<EOL>for index_point in range(len(self.__pointer_data)):<EOL><INDENT>index_optim = -<NUM_LIT:1><EOL>dist_optim = <NUM_LIT:0.0><EOL>for index in range(len(self.__medians)):<EOL><INDENT>dist = self.__metric(self.__pointer_data[index_point], self.__medians[index])<EOL>if (dist < dist_optim) or (index == <NUM_LIT:0>):<EOL><INDENT>index_optim = index<EOL>dist_optim = dist<EOL><DEDENT><DEDENT>clusters[index_optim].append(index_point)<EOL><DEDENT>clusters = [cluster for cluster in clusters if len(cluster) > <NUM_LIT:0>]<EOL>return clusters<EOL>
!
        @brief Calculate Manhattan distance to each point from the each cluster. 
        @details Nearest points are captured by according clusters and as a result clusters are updated.

        @return (list) updated clusters as list of clusters where each cluster contains indexes of objects from data.