find index of points in meshgrid under the line
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
I have 2D mesh grid of 501*2001. I want to get indices of values for the grid points in straight line to change the values of grid amplitude as shown in figure. ![Capture.JPG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/215490/Capture.jpeg)
![Capture.JPG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/215490/Capture.jpeg)
0 Commenti
Risposte (1)
KSSV
il 23 Apr 2019
Read about knnsearch. You will get the the required/ nearest indices for the given line from the grid.
4 Commenti
Vedere anche
Categorie
Scopri di più su Matrix Indexing in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!