real simple -- spreadsheet parsing

조회 수: 6 (최근 30일)
chang liu
chang liu 2020년 3월 27일
댓글: chang liu 2020년 3월 28일
got a spreadsheet with data like this , basically n by m matrix containing alpha-numerical values
i just want to reduce this to a numeric (double) matrix (2d array) containing only the middle number , i.e. the number that's in between the : and the (
like 1759, 1777,1755... the 4 digit number thats in the middle . i want to plot them out on a graph
the format is fixed
how do i do this

채택된 답변

Walter Roberson
Walter Roberson 2020년 3월 27일
You can use extractBetween() on the string array, and double() the result
  댓글 수: 1
chang liu
chang liu 2020년 3월 28일
worked like a charm!

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

chang liu
chang liu 2020년 3월 27일
since the format is fixed i was thinking maybe easy way is to just say ignore the first 6 or so characters, ignore the last 7 characters?
i am using importdata() and then convert to string by doing string()

카테고리

Help CenterFile Exchange에서 Spreadsheets에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by