1. A method of controlling the resolution of a hyperspectral image from an image sensor comprising pixels and at least one filter that defines subpixels within each pixel, the method comprising: defining a window on the image sensor comprising an array of rows and columns of subpixels, weighting the subpixels within the window based upon at least one predefined parameter of the hyperspectral image to establish a value for a weighted average for the array for the at least one predefined parameter, shifting the window by a predefined number of rows or columns wherein the predefined number is less than the number of respective rows or columns in the array, repeating the weighting and shifting steps for all possible arrays on the image sensor, and processing the hyperspectral image based on the weighted averages.