I need to load data from a .csv file and then save it in a dictionary in R.
There are ten thousands of lines of data entry that need to be loaded from a .csv file.
The data format:
country,region,value
1 , north , 101
1 , north , 219
2 , south , 308
2 , south , 862
... , ... , ...
My expected results that can be save in a data structure of R :
country , region, list of values
1 north 101 , 219
2 south 308 , 862
So that I can get the values that are associated with the same country and region.
Each row may have different country and region.
I need to save the value with the same country and region together.
Any help would be appreciated.