Learning from heterogeneous data based on social interactions over graphs