Kinetic and thermodynamic analysis of proteinlike heteropolymers: Monte Carlo histogram technique