I have a datime matrice called tid with 8761 values such as tid = datetime(2015,1,1,00,00,00):hours(1):datetime(2016,1,1,00,00,00);
I'm trying to remove all the times exept the ones from 08-16 i wrote:
for o = 9:24:8761-23
worktime(o,:) = tid([o:o+8],:)
now it alomst devides the timetable in the manner I needed however i was expecting a row and there are some other problems becouse i don't know how to remove the Not a Times (NaT) now (pic below). I'm sure there's a better way to do this than what i'm thinking with a loop but I also have a seperat matrice with values that needs to be seperated in the same manner later so I thought test with the time first. and i don't think i can use cells in the script i have becouse of the newbcoding on my part.
I hope things are clear on what i need to do..