clear all
close all

data = xlsread('DollarsSpent.xls');

idx = 3:44;

month = datenum(data(idx,1), data(idx,2), 28);

spent = data(idx,5);
cumulative_spent = data(idx,14);

linear_spendrate = data(idx,4);
planned_spendrate = data(idx,6);



figure('Position', [ 198         610        1101         403]);
fh = plot(month,cumulative_spent,month,linear_spendrate,month,planned_spendrate,[datenum(month(39)) datenum(month(38))],[0 linear_spendrate(end)],'--');
legend('Actual Spending','Linear Spend Profile','Planned Spend Profile','Location','NorthWest');
datetick('x','mmm-yyyy','keepticks');
ylabel('Thousands of Dollars');
xlabel('Date');
title('Spending through June 26, 2012');
foo = axis;
foo(1) = month(1);
foo(2) = month(end);
axis(foo);


print('-dpng','Spending through June, 2012');
print('-dpdf','Spending through June, 2012');

