I need help regarding the data manipulation in R .
My dataset looks something like this.
Name, country, age
Smith, Canada, 27
Avin, India, 25
Smith, India, 27
Robin, France, 28
Now I want to identify the number of changes that “Smith” has gone through (two) based on combination of Name and country only.
Basically, I want to compare each datapoint with other datapoints and identify the count of changes that have been there in the entire dataset for the combination of Name and Country only.