Limiting the values of a column
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hazem Al-Bulqini
am 14 Sep. 2020
Kommentiert: Hazem Al-Bulqini
am 14 Sep. 2020
I have a column 'y' contains different values. I want to only take the values between -10 and 10 in an other column.
How can I do that?
2 Kommentare
Akzeptierte Antwort
the cyclist
am 14 Sep. 2020
If you mean that y is a column vector, then
y_new = y((y>=-10) & (y<=10))
will give you a new column vector with only the values between (and including) -10 and 10.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Tables finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!