22 lines
720 B
Matlab
22 lines
720 B
Matlab
function [sidebarLabel] = sidebar_stats(pltData)
|
|
%SIDEBAR_STATS Summary of this function goes here
|
|
% Detailed explanation goes here
|
|
sidebarLabel = sprintf(...
|
|
"Statistics:\nEnergy\n Used: %.2f kWh\n" + ...
|
|
" Regen: %.2f kWh\n" + ...
|
|
" Total: %.2f kWh\n" + ...
|
|
"\nPower\n Peak: %.1f kW\n" + ...
|
|
" Peak (mean): %1.f kW\n" + ...
|
|
"\nDistance: %.2f km\n" + ...
|
|
"\nTopspeed: %.1f km/h\n", ...
|
|
pltData.energy_used_kwh, ...
|
|
pltData.energy_regen_kwh, ...
|
|
pltData.energy_kwh, ...
|
|
pltData.peakPower_kw, ...
|
|
pltData.peakPowerMean_kw, ...
|
|
pltData.distanceTotal_km, ...
|
|
pltData.maxSpeed_kph ...
|
|
);
|
|
end
|
|
|