A method of calculating a time-to-temperature estimate for a thermostat controlling an HVAC system, the method comprising: receiving a first temperature representing a current temperature of an enclosure; receiving a second temperature representing a target temperature of the enclosure to initiate an HVAC cycle; computing a global-model estimate of an estimated time representing an estimated time to transition the temperature in the enclosure from the first temperature to the second temperature by the HVAC system, wherein the global-model estimate is computed based on a global model selected from a plurality of global models associated with historical time and temperature values recorded from one or more previous temperature change cycles of the enclosure, the selected global model being associated with conditions closest to current conditions; computing a local model estimate of the estimated time based on tracking current temperature values of the enclosure versus time as the enclosure transitions from the first temperature towards the second temperature, wherein computing the local model estimate comprises building a local model based on the tracked current temperature values of the enclosure versus time by constructing a linear function fitting the tracked current temperature values, and projecting the linear function onto the target temperature; computing (2010, 2014, 2016) the estimated time as a weighted combination of the global-model estimate and the local model estimate, wherein a weighting of the global-model estimate and the local model estimate is incrementally modified for providing smooth transition between (i), at the beginning of the HVAC cycle, the weighted combination being equal to the global-model estimate, and (ii), at the end of the HVAC cycle, the weighted combination being equal to the local-model estimate; and causing (2010, 2016) the computed estimated time to be displayed on a display device as the estimated time, wherein computing the local model estimate based on tracking current temperature values comprises building up a local model for the local model estimate based on the tracked current temperature values while the global-model estimate is being used, and wherein incrementally modifying the weighting of the global-model estimate and the local model estimate is performed for providing smooth transition from the global model estimate to the local model estimate, when a statistically meaningful linear function fitting the tracked current temperature values has been constructed based on a sufficient amount of tracked current temperature values. receiving a first temperature representing a current temperature of an enclosure; receiving a second temperature representing a target temperature of the enclosure to initiate an HVAC cycle; computing a global-model estimate of an estimated time representing an estimated time to transition the temperature in the enclosure from the first temperature to the second temperature by the HVAC system, wherein the global-model estimate is computed based on a global model selected from a plurality of global models associated with historical time and temperature values recorded from one or more previous temperature change cycles of the enclosure, the selected global model being associated with conditions closest to current conditions; computing a local model estimate of the estimated time based on tracking current temperature values of the enclosure versus time as the enclosure transitions from the first temperature towards the second temperature, wherein computing the local model estimate comprises building a local model based on the tracked current temperature values of the enclosure versus time by constructing a linear function fitting the tracked current temperature values, and projecting the linear function onto the target temperature; computing (2010, 2014, 2016) the estimated time as a weighted combination of the global-model estimate and the local model estimate, wherein a weighting of the global-model estimate and the local model estimate is incrementally modified for providing smooth transition between (i), at the beginning of the HVAC cycle, the weighted combination being equal to the global-model estimate, and (ii), at the end of the HVAC cycle, the weighted combination being equal to the local-model estimate; and causing (2010, 2016) the computed estimated time to be displayed on a display device as the estimated time, wherein computing the local model estimate based on tracking current temperature values comprises building up a local model for the local model estimate based on the tracked current temperature values while the global-model estimate is being used, and wherein incrementally modifying the weighting of the global-model estimate and the local model estimate is performed for providing smooth transition from the global model estimate to the local model estimate, when a statistically meaningful linear function fitting the tracked current temperature values has been constructed based on a sufficient amount of tracked current temperature values.