## Plot tradeoff curves

#datapn = aload("profit/numunsrv/output.csv", Inf, Inf, ",");
datanp = aload("numunsrv/profit/output.csv", Inf, Inf, ",");

#datapd = aload("profit/numacdev/output.csv", Inf, Inf, ",");
datadp = aload("numacdev/profit/output.csv", Inf, Inf, ",");

#datand = aload("numunsrv/numacdev/output.csv", Inf, Inf, ",");
datadn = aload("numacdev/numunsrv/output.csv", Inf, Inf, ",");


# pnchart = [ datapn(:,18)'; datapn(:,16)' ]';

# gset term x11;
# figure (1);
# xlabel ("Profit");
# ylabel ("Number unserviced");
# title ("Unserviced Patrons vs. Profit Tradeoff Curve")
# gplot pnchart with points title "Tradeoff Curve";
# gset term postscript color;
# gset output "pnchart.ps";
# replot


dnchart = [ datadn(:,17)'; datadn(:,16)' ]';

gset term x11;
figure (2);
xlabel ("Deviation from desired fleet size");
ylabel ("Number unserviced");
title ("Profit vs. Deviation from desired fleet size Tradeoff Curve")
gplot dnchart with points title "Tradeoff Curve";
gset term postscript color;
gset output "dnchart.ps";
replot



# pdchart = [ datapd(:,18)'; datapd(:,17)' ]';

# gset term x11;
# figure (3);
# xlabel ("Profit");
# ylabel ("Deviation from desired fleet size");
# title ("Desired fleet size deviation vs. Profit Tradeoff Curve")
# gplot pdchart with points title "Tradeoff Curve";
# gset term postscript color;
# gset output "pdchart.ps";
# replot


dpchart = [ datadp(:,17)'; datadp(:,18)' ]';

gset term x11;
figure (4);
xlabel ("Deviation from desired fleet size");
ylabel ("Profit");
title ("Desired fleet size deviation vs. Profit Tradeoff Curve")
gplot dpchart with points title "Tradeoff Curve";
gset term postscript color;
gset output "dpchart.ps";
replot



# ndchart = [ datand(:,16)'; datand(:,17)' ]';

# gset term x11;
# figure (5);
# xlabel ("Number of unserviced patrons"); 
# ylabel ("Deviation from desired fleet size");
# title ("Unserviced Patrons vs. Deviation from desired fleet size Tradeoff Curve")
# gplot ndchart with points title "Tradeoff Curve"; 
# gset term postscript color;
# gset output "ndchart.ps";
# replot

 npchart = [ datanp(:,16)'; datanp(:,18)' ]';

gset term x11;
figure (6);
xlabel ("Number of unserviced patrons"); 
ylabel ("Profit");
title ("Number of Unserviced Patrons vs. Profit Tradeoff Curve")
gplot npchart with points title "Tradeoff Curve"; 
gset term postscript color;
gset output "npchart.ps";
replot


gset term x11;
