Python - Read and plot data from a .csv -
i have .csv full of gdp data year different countries. want read file , plot data of select few of countries in .csv file. far have:
data = np.genfromtxt('the_data.csv', dtype=str, delimiter=',', names=none, usecols=np.arange(0,17))
which think lets me read data. how use matplotlib generate graph of gdp change on years, of countries?
with open(the_data.csv) f: content = f.readlines() my_list=[] line in content: my_list.add(line.split(';') )
or use csv module https://docs.python.org/2/library/csv.html
Comments
Post a Comment