def split_by_link(data):
	"""
    splits PTCF information by link ids (e.g. "ds1_1-ds2_1") to store the data under a given key for easier access (-> focus-on-hover!)

    :param data: ptcf data frame
    :return: PTCF split by link
    """ 

	split_data = {}
	
	data['cluster_id'] = data['ds1_cluster'] + "-" + data['ds2_cluster']

	grouped = data.groupby('cluster_id')

	for x in grouped.groups:
		split_data[grouped.get_group(x)['cluster_id'][0]] = grouped.get_group(x).drop(columns=['cluster_id']).to_json(orient='records')

	return split_data