MATLAB: Delete empty [] {1×7 cell} {1×2 cell}

delete empty []

how delete []; when I have Z= [] {1×7 cell} {1×2 cell}
and i want to have Z= {1×7 cell} {1×2 cell}

Best Answer

z(cellfun('isempty',z))=[]