% DistFit.m % Script to iterate through journey length arrays for each hour of the day % and fit the weibull distribution to each of them. % These distributions are then saved entitled 'fithourmidlong%d' where %d % denoted the hour of the day. % % Author: George Hilton Email: g.hilton@soton.ac.uk % Date: 15/08/2017 for i1 = 1:24 str = sprintf('hourmidlong%d.mat',i1); load(str) if length(data) >= 2 %str2 = sprintf('fithourmidlong%d',i1); fithourlong(i1) = fitdist(data,'Weibull'); end clear str end