How much information is lost in this binary sequence? Given a sequence of $X= y_1, y_2 , ...,y_m$ binary data points. That means $y_i = 0 \text{ or } y_i=1$ for $i\in \{1,...,m\}$
Say that we select $n&lt;m$ datapoints, 'damage' our file such that we are not certain about the outcomes of those $n$ points. How much information is now lost?

For example, say we have a sequence 000000. Then we damage this file
such that we are not certain about the first 2 values any more (the
file now could be 000000, 010000, 100000 or 110000
Does this mean that we lose $\frac{2^2}{2^6}=4/64=$ 6,25% information?

My question is: In general, how much information is lost when we are not certain about $n$ chosen outcomes of the sequence. Alternatively asked: how much information do the $m-n$ datapoints contain when compared to the original $m$ datapoints?
And what about if the $m$ datapoints are not binary, but for example can take $3$, $4$ or $r\in \mathbb{N}$ values?
Im looking for a clear, comprehensive answer, in a general formula. Thank you :-)
Each entry $Y_k\in\{0,1\}$ of your vector $X=(Y_1,\ldots ,Y_m)$ incorporates $1$ bit of information; therefore a "measurement" of $X$ is worth $m$ bits. This statement implicitly assumes that the $Y_k$ are independent and assume the value $0$ or $1$ with probability ${1\over2}$ each, in other words: that all $2^m$ possible words $X$ are equiprobable.

If $n$ of the outcomes $y_k$ are corrupted, and you know the affected set $J\subset[m]$, then the information loss is $n$ bits, since such a measurement $x$ does not specify a point in $\{0,1\}^m$ exactly, but admits $2^n$ points compatible with $x$.

When it is only known that $|J|=n$, but $J$ is unspecified otherwise, then things are much more complicated.

When $2$ is replaced by some $r&gt;1$ in these arguments the information gained or lost per "correct digit" amounts to $\log_2 r$ bits.
First, notice that if a point is damaged such that it retains its original value, then there is no data loss. Now if $n$ out of $m$ point are perturbed we get an upper bound of $n/m$ data loss. But this supposes that the binary points were flipped (ie. $1$ became $0$ and vice-versa).

If damaged points are values taken at random in the set of possible values (here $\{0,1\}$) we get $P(dataloss)=1/2$. Hence the expected data loss would be $n/2m$.

Now, if the set of possible values is of cardinality $\mid X\mid$ the expected dataloss when $n$ elements out of $m$ are perturbed would be
$$E(\%\;of\;dataloss)=\frac{\mid X\mid-1}{\mid X\mid}\cdot\frac{n}{m}$$

This is, of course, assuming values in $X$ are equiprobable.

If the number of perturbed values is a random variable, then the formula can be rewritten as
$$E(\%\;of\;dataloss)=\frac{\mid X\mid-1}{\mid X\mid}P(digit\;is\;perturbed)\cdot M$$

But, the expected number of points you could not trust would be : $P(digit\;is\;perturbed)\cdot M$.