  Consider a subshift over a finite alphabet, $X\subset \Lambda^{\mathbb Z}$
(or $X\subset\Lambda^{\mathbb N_0}$). With each finite block $B\in\Lambda^k$
appearing in $X$ we associate the empirical measure ascribing to every block
$C\in\Lambda^l$ the frequency of occurrences of $C$ in $B$. By comparing the
values ascribed to blocks $C$ we define a metric on the combined space of
blocks $B$ and probability measures $\mu$ on $X$, whose restriction to the
space of measures is compatible with the weak-$\star$ topology. Next, in this
combined metric space we fix an open set $\mathcal U$ containing all ergodic
measures, and we say that a block $B$ is "ergodic" if $B\in\mathcal U$.
  In this paper we prove the following main result: Given $\varepsilon>0$,
every $x\in X$ decomposes as a concatenation of blocks of bounded lengths in
such a way that, after ignoring a set $M$ of coordinates of upper Banach
density smaller than $\varepsilon$, all blocks in the decomposition are
ergodic. The second main result concerns subshifts whose set of ergodic
measures is closed. We show that, in this case, no matter how $x\in X$ is
partitioned into blocks (as long as their lengths are sufficiently large and
bounded), after ignoring a set $M$ of upper Banach density smaller than
$\varepsilon$, all blocks in the decomposition are ergodic. The first half of
the paper is concluded by examples showing, among other things, that the small
set $M$, in both main theorems, cannot be avoided.
  The second half of the paper is devoted to generalizing the two main results
described above to subshifts $X\subset\Lambda^G$ with the action of a countable
amenable group $G$. The role of long blocks is played by blocks whose domains
are members of a F\o lner sequence while the decomposition of $x\in X$ into
blocks (of which majority is ergodic) is obtained with the help of a congruent
system of tilings.
