Prerequisite: Introduction to Social Networks
In the Fatman evolutionary model, there are 3 main concepts to make an evolutionary model i.e Homophily, Social influence, and closure.
- Homophily- People who are similar to each other, they tend to make friends with each other.
- Social Influence- People change their behavior and properties because of social influence.
- Closure- There are 3 main kinds of closures i.e triadic closure, membership closure, and foci closure.
- Triadic closure- In triadic closure, if A is a friend of B and B is a friend of C then C will eventually become friends of A.
- Membership closure- In membership closure, if A and B are in the same club then there is a tendency that they will become friends.
- Foci closure- It is the probability of becoming friends when they have the same foci.
So, According to Fatman Hypothesis, beware of fat friends, if your friend is fat then the probability of you gaining the weight becomes high.
Now the below code will show you the implementation of the above 3 concepts using the evolutionary model in python by taking an example.
Assume there is a city with a number of people, and we have everyone’s BMI. Then we will see as evolution continues people having similar BMI become friends to each other which is Homophily. Then we will create some foci like Gym etc. and see how eventually people with similar foci become a friend and then we will implement social foci.
- Create a graph with say N nodes,
- Add edges and labels for each node.
- Now add social foci and social foci label for each node
- .Now implement homophily.
- After that implement closure.
- At last implement social influence.
- Now Visualize the graph.
Python Code for Fatman Evolutionary Model:
The output contains graphs having homophily, closure, and change in behavior i.e social influence.
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course