Locate and extract values from one array to another
Afficher commentaires plus anciens
Hi guys, hope you doing well.
I have an array "data3" (113208576x3) with the variables "x", "y", "conc". I need to exctract from this array all the values where the "x" and "y" match an other array "SensorILM" i have (2001x4).
This is the code i tried:
load("November.mat");
load("Sensor_ILM.mat");
XILM = SensorILM.X;
YILM = SensorILM.Y;
idXmod = find(data3(:,1) == XILM)
idYmod = find(data3(:,2) == YILM)
I got the following error: "Arrays have incompatible sizes for this operation".
Do you know other way or method to do is or how to fix this error?
Thank you for your help!
Edit: I'm sorry but i didn't explain very well what i need. I want to extract the full rows of the array "data3" where the "x" and "y" match the "x" and "y" of the other array.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Matrix Indexing dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!