- In order to find PCC between 2 images, you first need to flatten the images, convert them into either row vector or column vector.
- The mathematical expression for PCC can be found out here.
- Looking at the expression, you need to find couple of things for each flatten images, which are mean and norm. So simply use the inbuilt MATLAB function for the same.
- Then simply take the dot product between them
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/589317/image.png)