Sunteți pe pagina 1din 1

Calculate a weighted average by

=SUMPRODUCT(<y-data>,<weights>)/SUM(<weights>)
(handle x-data analogously). The slope of weighted linear regression is
then
=SUMPRODUCT(<y-data>-<y-wtd_ave>,<x-data>-<x-wtd_ave>,<weights>) /
SUMPRODUCT((<x-data>-<x-wtd_ave>)^2,<weights>)
and the intercept of weighted linear regression is
=<y-wtd_ave> - <x-wtd_ave>*<wtd_slope>
These should work if there is no missing data. With missing data, you
must insure that the averages do not include unmatched data.
Jerry

S-ar putea să vă placă și