function [ error ] = MakeEffPlots(path,filename)


load([path filename '.mat']);
who

Force = (10*SC_LowerPressure-1.59)*(8758)/(262.7-1.59);

x = 10*SC_Range;
n = 10;
filtx = filtfilt(ones(1,n)/n,1,x);
x = filtx;

%x = (10*SC_UpperPressure-18.9)*(71.5-0)/(294.2-18.9);
v = [0 diff(x)/.1];


Pin = (Force*4.45).*(v*.0254);


%%Plot Force, Speed, and Mechanical Power In
figure('Position',[1000 525 1359 973]);
ah1 = subplot(4,1,1);
plot(Time_DateNum,x,Time_DateNum,SC_Range)
ylabel('Position (in)');
datetick('x');
legend('String Pot Position','RangeFinder Position');
ah2 = subplot(4,1,2);
plot(Time_DateNum,v,'-x')
ylabel('Speed (ips)');
datetick('x');
ah3 = subplot(4,1,3);
plot(Time_DateNum,Force);
ylabel('lbs');
datetick('x');
ah4 = subplot(4,1,4);
plot(Time_DateNum,Pin);
ylabel('Mechanical Power in (W)');
datetick('x');

linkaxes([ah1 ah2 ah3 ah4],'x');


Pout = PC_Voltage.*(PC_BattCurr+PC_LoadCurr);


%Plot Voltage, Current, and Electrical Power Out
figure('Position',[1000 525 1359 973]);
ah1 = subplot(3,1,1);
plot(Time_DateNum,PC_Voltage)
ylabel('Bus Voltage (V)');
datetick('x');
ah2 = subplot(3,1,2);
plot(Time_DateNum,PC_BattCurr,Time_DateNum,PC_LoadCurr)
ylabel('Current (A)');
legend('Battery Current','Load Current');
datetick('x');
ah3 = subplot(3,1,3);
plot(Time_DateNum,Pout);
ylabel('W');
datetick('x');

linkaxes([ah1 ah2 ah3],'x');



figure('Position',[1000 525 1359 973]);
ah1 = subplot(3,1,1);
plot(Time_DateNum,PC_RPM)
ylabel('RPM');
datetick('x');
ah2 = subplot(3,1,2);
plot(Time_DateNum,Pin,Time_DateNum,Pout)
legend('Pin','Pout');
ylabel('W');
datetick('x');
ah2 = subplot(3,1,3);
plot(Time_DateNum,100*Pin./Pout)
ylabel('Eff (%)');
datetick('x');
linkaxes([ah1 ah2 ah3],'x');


end

