Distribution of frequencies of digits via multifractal analysis