book_entry['rank'] = (avg_karma_count * avg_karma + book_entry['karma'] * book_entry['karma_count']) / (book_entry['karma_count'] + avg_karma_count)