How to copy content of of 7*14 matrix file(*.mat) to a table on Microsoft Word??
Afficher commentaires plus anciens
How to copy content of of 7*14 matrix file(*.mat) to a table on Microsoft Word??
Réponses (2)
Image Analyst
le 30 Juin 2015
0 votes
If you're using Windows, you have to use ActiveX to have MATLAB directly control Word. I'm attaching a program to use it with Excel, but you can search the forum to see if anyone has used it with Word.
5 commentaires
Nisreen Sulayman
le 30 Juin 2015
Brendan Hamm
le 30 Juin 2015
The format commands only change how MATLAB is displaying the values to your MATLAB command window, however they are still stored in memory as double precision. You can convert them to char arrays with the rounding performed and place these into a Word Cell.
a = 0.943636363636364;
num2str(a,'%0.2f')
ans =
0.94
Nisreen Sulayman
le 1 Juil 2015
Modifié(e) : Nisreen Sulayman
le 1 Juil 2015
Nisreen Sulayman
le 3 Juil 2015
Image Analyst
le 3 Juil 2015
Appear where? If you used format bank and just left off the semicolon, the number should echo to the command window with only two numbers to the right of the decimal point. What did you do (apparently it wasn't this)?
Thorsten
le 3 Juil 2015
0 votes
Catégories
En savoir plus sur ActiveX dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!