Defining a save name
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
file_name = input('what is the file name? \n')
SAVEAS(figure(1),file_name,'fig')
hi i am a complete novice at matlab, i have the code above which i want to use to save my figure, i want however the user to define the file name?.. is this even possible any help would be great, thanks in advance
Kyle
0 comentarios
Respuesta aceptada
Sean de Wolski
el 5 de Abr. de 2011
file_name = input('what is the file name? \n','s')
Note the 's' at the end of input. It will return a string now not a number which can be used as a valid file name. Welcome to MATLAB Answers!
Más respuestas (0)
Ver también
Categorías
Más información sobre Printing and Saving en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!