title: Creating a subset in R using a double loop Continuation
body: <p>DF:</p>
  
  <p>Year 1901  1901  1903  1968 1978 2002 2006 2010</p>
  
  <p>species    1      1    2      65   1    82   3   1</p>
  
  <p>lat:  49   46   47    47   48   43.1  44.23  47.11</p>
  
  <p>long:  -79.22 -79.5  -78.22 -79.84 -78.11  -77.114  -76.33  -76.2</p>
  
  <p>Julian_Day: 79  125   165   178   193  68  90  230   </p>
  
  <p>Land:   16   24  25  30   34   34  39   41   </p>
  
  <p>There are more variables but that's an example of the matrix. I only want to keep the rows for each year AND for each species that has the lowest value for the Julian_day. Ie: the second row would be omitted here, because 79 is less than 125 for species 1 in 1901.</p>