매트랩 txt 파일 읽어오기
31 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1810818/image.jpeg)
이런 형태의 파일을 읽어와 조화분석을 시도하려고 했는데, 파일을 읽어올 때 구분자를 어떻게 사용해야 ![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1810823/image.jpeg)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1810823/image.jpeg)
이런식으로 데이터를 받아와 사용할 수 있는지 궁금합니다. 참고할만한 방법을 알려주시면 감사할 것 같습니다..
0 commentaires
Réponse acceptée
JWH
le 21 Nov 2024
위의 링크를 참고해서 할경우 아래와 같이 될것 같습니다.
t1 = readtable('test.txt', 'ReadVariableNames', false);
t1.Properties.VariableNames{1} = 'Date';
t1.Date.Format = 'yyyy-MM-dd HH:mm:ss';
t1.Properties.VariableNames{3} = 'Num';
t2 = table(t1.Date, t1.Num);
Plus de réponses (0)
Voir également
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!