How to convert a cell array of datetime to an array of datetime
조회 수: 35 (최근 30일)
이전 댓글 표시
Hi, Is there a simple way to convert a cell array of datetime to an array of datetime without using cellfun? My cell array looks like:
32×1 cell array
{[01-May-2018]}
{[01-May-2018]}
{[01-May-2018]}
{[01-May-2018]}
{[01-May-2018]}
{[01-May-2018]}
I would like it to be just an array of datetime. Thanks for any help.
댓글 수: 0
채택된 답변
Ameer Hamza
2018년 5월 29일
Try this
array = [cellArray{:}];
[] symbol are necessary to form an array.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Data Type Conversion에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!