Read text file and separate text from numerical values
이전 댓글 표시
I have a text file that is output from an inspection machine, and looks like the attached file, just with a lot more holes. I am trying to create a matlab program that takes the values from this text file and puts them in to a template in excel and saved as a new excel file. The excel template has equations and plotting function that just needs the values placed in the empy fields, and is currently done by opening the text file in excel and doing the import, then copy and pasted over to the excel template. It works but is slow.
I want to take the values for each hole number, even though the only thing changing is the 'actual' values, and save them in an array so it's easier to place in excel. I can't find a good way to separate the row text from the numbers themselves, especially since there are multiple values on a row. Other than the first hole the data follows the same pattern of a description, diameter, x location, y location. The best I have so far is reading it in to a table where each row in the table is one row from the file. So it's a start but not a great one.
Maybe I'm overcomplicating the process too, but any help is appreciated.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Spreadsheets에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!