필터 지우기
필터 지우기

Create text variable from one other

조회 수: 1 (최근 30일)
Berkay
Berkay 2022년 8월 30일
답변: Chunru 2022년 8월 30일
I have created a text variable as;
Text = "Alex"
and I want to create an other text varible with every second letter of the "Text" varible(Alex). How can I do it?

채택된 답변

Chunru
Chunru 2022년 8월 30일
% Use char array
Text = "Alex"
Text = "Alex"
Text1 = char(Text);
Text2 = string(Text1(1:2:end))
Text2 = "Ae"

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Text Data Preparation에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by