Saving to structured variable in loop
Show older comments
Hi This is part of my code:
for i=1:18
for j=i+1:19
x = data(i,:);
y = data(j,:);
wcoh.(i,j)=wcoher(x,y);
end
end
Function wcoher computes from two rows of data one matrix. But i have 19 rows of data. And i want to compute wcoher for each pair. So the result would be structured variable for example wcoh->inside it variables 1-2,1-3,1-4,....5-6,...18-19-> and inside matrix computed by wcoher function.
Thx for help!!
2 Comments
Andrei Bobrov
on 14 Mar 2013
What are return wcoher ? Scalar or array?
Jakub
on 14 Mar 2013
Accepted Answer
More Answers (0)
Categories
Find more on Parallel Computing 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!