title: ' vectors must be the same length' error
body: <p>I've got a 250 x 250 image, I want to have a scatter plot of the intensity of every pixel and its nearest neighborhood. This is my code:</p>
  
  <pre><code>I = imread(image);
  i = [1,249];
  j = [1,250];
  X = I(i,j);
  Y = I(i+1,j);
  scatter(X,Y);
  </code></pre>
  
  <p>why do I get the " X and Y vectors must be the same length" error? They are the same length !</p>