필터 지우기
필터 지우기

change output filename in a loop

조회 수: 3 (최근 30일)
Mohammad
Mohammad 2012년 11월 15일
Hello. I have a series of variable like g_1,g_2.....g_n that produced in a for loop I want to save each of them in a individual text file like g_1.txt,g_2.txt ,... how can i do that?. could you please help me?. for example: for i=1:10 g_i=i; save g_i.txt g_i -ascii end I don't know how change the g_i.txt in a loop thank you.

답변 (1개)

Matt Fig
Matt Fig 2012년 11월 15일

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by