Is there a way to save a .mat file with a variable as a filename?

1 次查看(过去 30 天)
Hello!
I have a variable defined in my workspace.
Example:
sitename =
US-FR2
How could I save a .mat file with this as the filename (US-FR2.mat), without typing it in manually?
Mil gracias

采纳的回答

Walter Roberson
Walter Roberson 2013-6-5
save(sitename);

更多回答(1 个)

Kate
Kate 2013-6-5
Thanks

类别

Help CenterFile Exchange 中查找有关 MATLAB 的更多信息

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by