How to store words from a string in a cell array as a multiple strings

Hi, I have a 1x1 cell array containing a string of words:
{'Date,Hour,Latitude,Longitude,Windspeed,Pressure'}
How would you extract each of those words individually from the string and store them perhaps in a 1x6 cell array?

 채택된 답변

Jonas
Jonas 2021년 6월 25일
편집: Jonas 2021년 6월 25일
use the function strsplit() here with Delimiter ','
if your cell has name a, use
strsplit(a{1},',')

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Characters and Strings에 대해 자세히 알아보기

제품

릴리스

R2021a

질문:

2021년 6월 25일

편집:

2021년 6월 25일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by