Using variable value to name a folder

hi, i have a variable called Name in workspace and would like to save a table to csv using the Name value. Example: Name=4205; writetable(T,?????);
name of output file should be 4205.csv
thanks!

 採用された回答

Azzi Abdelmalek
Azzi Abdelmalek 2016 年 4 月 25 日
編集済み: Azzi Abdelmalek 2016 年 4 月 25 日

1 投票

Name=4205;
writetable(T,sprintf('%d.csv',Name));

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeTables についてさらに検索

質問済み:

2016 年 4 月 25 日

コメント済み:

2016 年 4 月 25 日

Community Treasure Hunt

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

Start Hunting!

Translated by