i have a csv file containing data, i have a column that contains positive and negative values and i need to plot the mean of this column in a way to have 2 bars , one for the negative values and one for the positive values. Take a look on my data :
timestamp,heure,lat,lon,ampl,type
2006-01-01 00:00:00,13:58:43,33.837,-9.205,10.3,1
2006-01-02 00:00:00,00:07:28,34.5293,-10.2384,17.7,1
2007-02-01 00:00:00,23:01:03,35.0617,-1.435,-17.1,2
2007-02-02 00:00:00,01:14:29,36.5685,0.9043,36.8,1
....
2011-12-31 00:00:00,05:03:51,34.1919,-12.5061,-48.9,1
i am using this code to plot my data :
names =["timestamp","heure","lat","lon","ampl","type"]
data = pd.read_csv('flash.txt',names=names, parse_dates=['timestamp'],index_col=['timestamp'], dayfirst=True)
data['ampl'] = data['ampl'].abs()
yearly = data.groupby(data.index.month)['ampl'].count()
ax = yearly.plot(kind='bar')
so, i need to disassociate the values of the column in question and have 2 bars instead of one , how can I proceed ?