First, I would recommend finding a reliable method of determining the week number of a particular date. If you have access to R2014b or later, you can use the week function. An alternative is also available on MATLAB File Exchange.
From there, you can use a loop and logical indexing to find the means of each week:
%sample dates
t = datetime(2015,05,31):datetime(2015,06,18)
%week numbers
w = week(t)
%sample data
data = randi(10,1,19)
%mean for week 24
mean_24 = mean(data(w == 24))