IS THERE ANY INBUILT TO CALCUALTE MEAN AND VARIANCE IN MATLAB
古いコメントを表示
Step 1 : Read a color image 0 with size NX N. Step 2: Calculate the trichromatic coefficients for each pixel according to equation (1) Step 3: Decompose the image recursively by quadtree partitioning. 1) Partition the image in 4 non-overlapped blocks with size N/2xN/2
2) For each such a block, calculate the average trichromatic coefficient and variances according to equations (2)-(3). THIS IS MY ALGORITHM WHICH I AM IMPLEMENTING...BUT I GOT THE PROBLM IN CALCULATING THE MEAN OF A BLOCK..ABOVE I HAVE MENTION THE STEPS OF MY ALGO.
回答 (1 件)
Jos (10584)
2013 年 10 月 9 日
If a block means a N-by-M matrix called, e.g., BLOCK, you can get the mean of all N*M elements using
mean(BLOCK(:))
カテゴリ
ヘルプ センター および File Exchange で Neighborhood and Block Processing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!