title: Need help finding the maximum value in a column in Google Sheets using Google Apps Script
body: <p>I have a sheet with a couple of thousand rows and 2 columns.  I need to write a script that will increment be row and compare the value in one of the columns to the previous 50 values in the same column and see if it is larger than the maximum value of the 50 previous entries.</p>
  
  <p>I've been trying to use Math.max(), but can't find the correct syntax to use to get that to work on a dynamic range.</p>