how to feed one string to array on NaN?
이전 댓글 표시
Dear MATLABERs :)
Is it possible to add a string to an array of NaN The next example does not work N = NaN(10,1); N(5,1)='Stop'; the result should be a column of NaN but the fifth element is Stop.
Thanks Aziz
채택된 답변
추가 답변 (2개)
James Tursa
2017년 1월 19일
1 개 추천
No, you can't combine character strings as elements of a numeric array like that. To combine different data types in one variable, consider using a cell array.
카테고리
도움말 센터 및 File Exchange에서 Cell Arrays에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!