how to remove spaces in a string?

조회 수: 265 (최근 30일)
Chiara Scarpellini
Chiara Scarpellini 2021년 5월 12일
댓글: Chiara Scarpellini 2021년 5월 12일
I would like to remove the white spaces in every string of this vector “Ly R4” “Ba R7” “Ty Ru”

채택된 답변

Stephan
Stephan 2021년 5월 12일
A = ["Ly R4", "Ba R7", "Ty Ru"]
A = 1×3 string array
"Ly R4" "Ba R7" "Ty Ru"
B = erase(A," ")
B = 1×3 string array
"LyR4" "BaR7" "TyRu"

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Cell Arrays에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by