MATLAB Answers

Delete element of an array on the basis of other arrays

2 views (last 30 days)
luca
luca on 14 Oct 2019
Commented: luca on 14 Oct 2019
Hi given arrays
Y= [175 175 175 175 175 175 175 175 175 175 175 175];
SETT=[178 130 120 140 100 160 179 165 157 140 130 180 140];
and
T = [25 60 50 40 30 30 30 35 10 34 23 45 12];
Considering each column, I want to create a new vector U where I put just the value of T where the element on the saem column of SETT does not exceed the value in Y.
So in this case I want to obtain
U=[60 50 40 30 30 35 10 34 23 12].
May someone helo me with the code?

  0 Comments

Sign in to comment.

Accepted Answer

madhan ravi
madhan ravi on 14 Oct 2019
U = T(Y>SETT)

  2 Comments

madhan ravi
madhan ravi on 14 Oct 2019
You have asked some advanced questions before, but I have no idea why you were struck in this one. I suggest you to do MATLAB onramp course to understand the basics of MATLAB.

Sign in to comment.

More Answers (0)

Sign in to answer this question.

Tags

Products


Release

R2019b

Translated by