MATLAB: How to create new cell array from old cell array

arraycellcell arrayssort

If I have a single column cell array of formatted date/times and i am trying to create a new array composed of the cell from every 3rd row of the original array what code should I use?
Example:
Input –
01/01/16
02/01/16
03/01/16
04/01/16
05/01/16
06/01/16
Output –
03/01/16
06/01/16

Best Answer

Try this:
outputCellArray = inputCellArray(3:3:end);