Creating multiple python dictionaries from a file
So I have no idea where to begin here but I need to take the information from a file similar to http://archive.ics.uci.edu/ml/machine-learning-databases/iris/iris.data and have the program run a function that will return 3 new dictionaries based on type. In this file there are 3 flower types so I need to have the program read the file and take the measurements and put them in dictionaries for the type of flower. (I hope I am being clear). From there I have a lot that I will have these dictionaries do for other functions but I know how to do that just not sure how to sort this file into the three dictionaries. I am using Python 2.7. Thanks all.
Read the file line by line. Split each line on ','. Have a dictionary with key as flower type and list of measurements being value. Each time, you get new measurements for the type append to the list.