This paper presents a novel model for analyzing the echo chamber phenomenon in social media. Extending the existing "gravity well" model, we add a variable that dynamically reflects a user's confirmation bias. This variable is calculated by comparing a user's posting history with their responses to posts from various perspectives. The improved model incorporates confirmation bias to more accurately identify echo chambers and provides a community-level indicator of information health. We validate the model on 19 Reddit communities, confirming its improved echo chamber detection performance. In conclusion, this study provides a framework that systematically captures the role of confirmation bias in online group dynamics, which can contribute to more effective identification of echo chambers and curbing the spread of misinformation.