Good example for jameson_uk and also a good example for justifying this Feature Request:
If it were implemented, you would be able to reduce the Template Sensor to this:
template:
sensor:
- name: "average_household_temp"
state_class: measurement
device_class: temperature
unit_of_measurement: "°F"
icon: mdi:home-thermometer-outline
variables:
items: "{{ expand('group.indoor_thermometers')| rejectattr('state', 'in', ['unavailable', 'unknown', 'NaN'])| map(attribute='state') | map('float', 0) | list }}"
state: "{{ (items | sum / items | count) | round(0, 0) }}"
availability: "{{ items | length == 0 }}"
attributes:
min: "{{ items | min }}"
max: "{{ items | max }}"