how to find index of the double
Mostra commenti meno recenti

i want to find the indese of the following data
what should be the code for this
1 Commento
Jan
il 29 Mag 2021
The question is not clear. What are "the following data"? Do you want to sort the vector?
Risposta accettata
Più risposte (1)
Asmit Singh
il 29 Mag 2021
Modificato: Image Analyst
il 11 Nov 2021
In my understanding you are trying to find an index of a particular value in double. You can use the find function. You can know more using the documentation here. Here is code for a simple example.
% Load your covid double data into "a".
a
% Search for the value 1000
index = find(a == 1000);
4 Commenti
Muhammad
il 29 Mag 2021
Asmit Singh
il 29 Mag 2021
What do you mean by index of all data? Do you mean that you want to load the data into your workspace ?
ganesh gng
il 11 Nov 2021
In the following example if I want to find data 1122, output should be its index which is 6,
Is there any way to do this?
Jan
il 11 Nov 2021
Modificato: Image Analyst
il 11 Nov 2021
Use the code show in this answer already:
index = find(covid == 1122)
Categorie
Scopri di più su Biological and Health Sciences in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!