Affinate the algorithm of "selected_day" and "selected_week" analysis.