Effacer les filtres
Effacer les filtres

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

2 vues (au cours des 30 derniers jours)
Shinichiro Shimata
Shinichiro Shimata le 2 Avr 2021
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 commentaire
Shinichiro Shimata
Shinichiro Shimata le 2 Avr 2021
It also says "Invalid data type. First argument must be numeric or logical."

Connectez-vous pour commenter.

Réponse acceptée

Walter Roberson
Walter Roberson le 2 Avr 2021
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

Plus de réponses (0)

Catégories

En savoir plus sur Tables dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by