Effacer les filtres
Effacer les filtres

How to save to .txt using WRITEMATRIX ?

2 vues (au cours des 30 derniers jours)
도현 김
도현 김 le 17 Mar 2021
Commenté : Mathieu NOE le 18 Mar 2021
M=ones(1,5)
writematrix(M,'M.txt','Delimiter','tab');
>> 1 1 1 1 1
but i want to : 1.00000000000000e+000 1.00000000000000e+000 1.00000000000000e+000 1.00000000000000e+000 1.00000000000000e+000
how can i get it ?

Réponse acceptée

Mathieu NOE
Mathieu NOE le 17 Mar 2021
writematrix(num2str(M,'% .14e'),'M.txt','Delimiter','tab');
  2 commentaires
도현 김
도현 김 le 18 Mar 2021
thank you ! ! ! !
Mathieu NOE
Mathieu NOE le 18 Mar 2021
you're welcome

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Data Import and Export dans Help Center et File Exchange

Produits


Version

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by