From: Jimmy on 11 Feb 2010 17:53 Hello everyone, I have a small question which I need some help with. I have 200 images and I have taken some measurements from each image. I want to create a for loop which will put those measurements into a data structure. Here's my for loop: for I=1:200 Z{i}= []; for i = 1:I for k = 1:numberOfBlobs Z{i}(1,k)= blobMeasurements(k).Centroid(1); Z{i}(2,k)= blobMeasurements(k).Centroid(2); end end end Can someone help me to coorect it if he knows how, so that when I type Z{1} which corresponds to image one, for example it will give me a data structure like this: Columns 1 through 8 12.8500 42.3077 43.8571 46.6000 60.2000 62.1429 71.6875 80.0000 13.7000 57.0000 104.9286 141.4000 158.0000 32.7143 216.0625 18.5000 Columns 9 through 16 82.1429 86.2727 88.1875 90.6667 108.0000 109.3333 135.5500 134.0000 62.9286 135.7273 24.1875 185.6667 118.5000 188.7619 150.3500 160.7059 Columns 17 through 24 141.5000 147.6471 165.8500 166.2353 168.0000 171.4737 182.3684188.5263 110.5000 180.0588 115.7500 107.2941 140.5000 38.6316 11.5789 56.8947 Thank you Jimmy
|
Pages: 1 Prev: execute a matlab script from a web page Next: Is there an "about equal" function? |