Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: divide 1280-by-960 image into 9-by-9
Date: Thu, 26 May 2011 19:12:05 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 32
Message-ID: <irm8m5$58n$1@newscl01ah.mathworks.com>
References: <irm4h1$jke$1@newscl01ah.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: www-06-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: newscl01ah.mathworks.com 1306437125 5399 172.30.248.38 (26 May 2011 19:12:05 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 26 May 2011 19:12:05 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 2799711
Xref: news.mathworks.com comp.soft-sys.matlab:728908

"areeba khan" wrote in message <irm4h1$jke$1@newscl01ah.mathworks.com>...
> i am working on a project detection of skin cancer using image processing..i have found a reference matrix of 9-by-9 of tumourous cell now through looping i want 2 compare this reference matrix with the image...   bt my program is giving this error                                                        
> ??? Error using ==> mat2cell
> Number of input vector arguments, 9, does not match the input matrix's number of dimensions, 2. 
> this is my code
> i=imread('E:\cancer images\case 091610\20X1.jpg');
> a=rgb2gray(i);
> b=imadjust(a);
> v=MAT2CELL(b,1,2,3,4,5,6,7,8,9);
> mat1=b(725:733,231:239);
> c=mat1;
> for t=1:size(c,2)
>     for u=1:size(c,1)
>         y=xcorr(c(:),b(:));
>        if y>=0.7
>            disp('Tumor detected')
>            else
>            disp('tumor not found')
>        end
>     end
> end
> please tell me if i am doing right?
> tell me some way how i can divide the real image 1280-by-960 into 9-by-9?

Hello,

May I suggest something ? Please reformulate your question. Looking at your words and then at your code is very confusing !

Are you trying to analyze a 9x9 chunk of the big matrix ? What are you going to do at the borders? Where are you using "v" in your code , after that attempt of allocation? Why are you doing 81 times the same operation ? ...

Regards,
Florin