Error in save to .txt

Hello, I am having difficulty saving data to a .txt file. The code provided by the research study is
if save_status == 1
save Daily_Infectivities.txt c -ascii -double -tabs
xlswrite('Daily_Infectivities.xlsx', c, 4)
end
However, I keep getting the error
Error using save
Unable to write file Daily_Infectivities.txt: permission denied.
Error in model_GUI_1_0>pushbutton1_Callback (line 294)
save Daily_Infectivities.txt c -ascii -double -tabs

Respuestas (1)

James Tursa
James Tursa el 29 de Oct. de 2014

0 votos

Where are you running the code from? Can you switch to a working directory where you do have write capability before doing the save?

Categorías

Más información sobre File Operations en Centro de ayuda y File Exchange.

Etiquetas

Preguntada:

el 29 de Oct. de 2014

Respondida:

el 29 de Oct. de 2014

Community Treasure Hunt

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

Start Hunting!

Translated by