How can I write a magic(5) matrix to a text file with special delimiters?
    3 visualizaciones (últimos 30 días)
  
       Mostrar comentarios más antiguos
    
    ARAH MIZORI
 el 13 de Sept. de 2021
  
    
    
    
    
    Respondida: Chunru
      
      
 el 13 de Sept. de 2021
            I want to a matrix in txt for with the delimeter %%%
0 comentarios
Respuesta aceptada
  Chunru
      
      
 el 13 de Sept. de 2021
        x = magic(5);
fid = fopen('test.txt', 'w');
fprintf(fid, '%f\n', x);  % try different format here
fclose(fid)
type('test.txt')
0 comentarios
Más respuestas (0)
Ver también
Categorías
				Más información sobre Low-Level File I/O 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!