JQ: Added comments, and small fix cding to correct file before making histogram and possibly cleaning up memory.