Shweta, I'm not sure about what kind of problem you're facing to. In my opinion, you should compare, first of all, the number of beats you detected against the number of true beats reported on MIT-BIH database for each record. This will allow you then to calculate sensitivity (Se) and predictability P+ of your QRS detector (please find attached calculation formulas).
The results' comparison problem was due to combined annotations of beats as well as non-beats in given .atr file from MIT-BIH database. Beats annotations were needed to be separated from non-beats annotations before being compared with the obtained QRS detection result to get accurate values for TP, FP and FN. Through proper programming, it was then possible and my problem was solved.