MATLAB: How to extract certain columns in a vector and store it as a new vector

air pollutionarraycolumncolumn vectorextracting dataindexingmatrixozonevector

I have a a 365×30 vector called OzoneData that contains ozone pollution data per day in a year (365) and from 30 different sites. I want to take all the ozone concentrations from columns 1,27,28,15, and 13 (sites) and store them in a different vector called Group1. How can I do this?
Thank you!

Best Answer

Group1 = OzoneData(:,[1,27,28,15,13]);
Related Question