필터 지우기
필터 지우기

Unable to use min( ) because the table is an index.

조회 수: 2 (최근 30일)
Shinichiro Shimata
Shinichiro Shimata 2021년 4월 2일
댓글: Shinichiro Shimata 2021년 4월 2일
When trying to use min( ) function, I get an error message saying "Unable to use a value of type table as an index". How can I fix it? The table is a 26999x1 table in Workspace and was imported from an excel spreadsheet.
  댓글 수: 1
Shinichiro Shimata
Shinichiro Shimata 2021년 4월 2일
It also says "Invalid data type. First argument must be numeric or logical."

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

채택된 답변

Walter Roberson
Walter Roberson 2021년 4월 2일
The table as index error suggests that you accidentally created a variable named min but also tried to call min() on a table.
You cannot apply min() to a table: you need to extract content from the table to apply min()
min(T{:, :} )
for example

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by