title: Distance function for sas 9.2
body: <p>In SAS 9.3 we can easily calculate the Euclidean distance matrix between lat, lon  by using function <code>distance</code></p>
  
  <pre><code>proc iml;
  n=5; 
  seed=123456789;
      lat= J(n,1,0); lon= J(n,1,0);
      i = 1;  do while (i &lt;= n); 
      lat[i] = uniform(seed);                                                                                                  
      lon[i] = uniform(seed);                                                                                                  
       i = i + 1;  end;
  mat=lat||lon;
  dist=distance(mat); 
  run;
  quit; 
  </code></pre>
  
  <p>I can't find this function in SAS 9.2
  How can I do it in 9.2 ?</p>
  
  <p>Thank you.</p>