Remove rows from matrix based on condition
13 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I have a matrix of (125000x2),(row, column). The first column is time, and the second column is the measured voltage value from an experiment. I want to delete the rows if the measured voltage value is less (-0.08) or bigger than (0.08).
0 Commenti
Risposta accettata
Dyuman Joshi
il 5 Apr 2023
%Let "in" be your matrix
%Finding the rows that meet this condition
idx = in(:,2) > 0.08 | in(:,2) < -0.08;
%Deletion
in(idx,:)=[];
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Sensors and Transducers 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!