excluderho

## Answered question

2022-06-29

Derivation of formula for mean of a dataset after adding a new data point
I was reading an article that stated that if we know the mean ${\overline{x}}_{prev}$ of a dataset with n datapoints, and that if we add a new data point ${x}_{k}$ to the dataset, then the new mean ${\overline{x}}_{new}$ can be expressed by the formula:
${\overline{x}}_{new}=\frac{1}{n+1}\sum _{i=1}^{n+1}{x}_{i}=\frac{1}{n+1}\left({x}_{k}+\sum _{i=1}^{n}{x}_{i}\right)$
It is not obvious to me how this expression is true.
This is my attempt at deriving the expression:
${\overline{x}}_{new}=\frac{1}{n+1}\sum _{i=1}^{n+1}{x}_{i}=\frac{1}{n+1}\left({x}_{k}+\sum _{i=1}^{n}{x}_{i}\right)$
Note that $\sum _{i=1}^{n}{x}_{i}=n{\overline{x}}_{prev}$
${\overline{x}}_{new}=\frac{1}{n+1}\left({x}_{k}+n{\overline{x}}_{prev}\right)$
but is does not seem like this is getting me anywhere.

### Answer & Explanation

Jovan Wong

Beginner2022-06-30Added 23 answers

${\overline{x}}_{new}=\frac{1}{n+1}\left({x}_{k}+n{\overline{x}}_{prev}\right)={\overline{x}}_{prev}+\frac{1}{n+1}\left({x}_{k}+n{\overline{x}}_{prev}-\left(n+1\right){\overline{x}}_{prev}\right)$

Do you have a similar question?

Recalculate according to your conditions!

Ask your question.
Get an expert answer.

Let our experts help you. Answer in as fast as 15 minutes.

Didn't find what you were looking for?