How to load the data in this case?

4 views (last 30 days)
As shown in the image there are two data sets 'a' and 'b'. How to load the data of 'b' into another variable, if a>0.1 and a<0.8?

Accepted Answer

Salaheddin Hosseinzadeh
Salaheddin Hosseinzadeh on 29 May 2015
Is that a excel file?! I don't get what you mean by loading.
If you just want to select some values do it like this.
c = a.*(a>0.1 & a<0.8);
So in variable c you will have what you want!
R7 DR on 29 May 2015
Hi Thanks..its working. But I have one more question.
How to modify the code if we have multiple variables. For example: 'b', 'c', 'd' and 'e' are the variables and the IF condition is same. Data is imported to matlab from excel.
In this case how to load the data from the specific variable for example:'e'

Sign in to comment.

More Answers (0)


Find more on Data Import from MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!