Input files editing format
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
RAKESH KUMAR TOTA
le 18 Jan 2021
Commenté : RAKESH KUMAR TOTA
le 18 Jan 2021
Hi, Good morning
I have an input file input.txt, i need to save the format in different two files node.txt and el.txt in the format attached files. Any help would be appreciated . Thank you inadvance.
2 commentaires
Réponse acceptée
Walter Roberson
le 18 Jan 2021
fid = fopen('input.txt', 'r');
nodedata = cell2mat( textscan(fid, '%*f,%f,%f', 'CommentStyle', {'*Heading', '*Node'}) );
eldata = cell2mat( textscan(fid, '%*f,%f,%f,%f,%f', 'HeaderLines', 1) );
fclose(fid)
8 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Data Import and Export dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!