data = readtable("data\20240805_SN029_pHtest_responsetime_trimmed.txt");
%%
time = abs(data.MM_DD_YYYYHH_MM_SS(1) - data.MM_DD_YYYYHH_MM_SS);
figure(1)
clf
plot(seconds(time),data.Vrse)
xlabel('seconds')
ylabel('vrse')
xline(224,'--')
xline(389,'--')
xline(448,'--')
xline(532,'--')
xline(595,'--')
xline(648,'--')

% 135:177
% 229:264
% 272:294
%% roughly calculate the 95% response time of the sensor
responsetime95 = data.MM_DD_YYYYHH_MM_SS(177) - data.MM_DD_YYYYHH_MM_SS(135)
responsetime95 = data.MM_DD_YYYYHH_MM_SS(264) - data.MM_DD_YYYYHH_MM_SS(229)
responsetime95 = data.MM_DD_YYYYHH_MM_SS(294) - data.MM_DD_YYYYHH_MM_SS(272)
%%