Hello community, I'm trying to optimize the speed of a code using Parallelize and Compile but I'm not having very expressive results (I'm still inexperienced in these commands). I believe that I am using these commands in an inefficient way (my attempt is at the end of the post)... below is explained where is the problem for my case in detail. First I'll explain the context of my question and then explain what I want to do.
Taking the table of the following numbers for example:
z = 5;
FromDigits[Table[10^x - 1, {x, {Range[z]}}]]

I then transformed into integers composed of sequential numbers as follows:
z = 2;
FromDigits[Table[10^x - 1, {x, {Range[z]}}]]
g[k_] := (ToExpression[
StringDelete[
ToString[Table[i, {i, Range[k]}]], {"{", "}", " ", ","}]]);
Table[g[j1], {j1, FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]

To count the different digits of each of these numbers:
z = 6;
g[k_] := (DigitCount[
ToExpression[
StringDelete[
ToString[Table[i, {i, Range[k]}]], {"{", "}", " ", ","}]]]);
Table[Print[g[j1]], {j1,
FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]

And finally, make a relationship (ratio) between the number of digits ´0´ (which is less than any other digit) and another digit (e.g. ´2´):
z = 6;
g[j_, h_] := (Take[
DigitCount[
ToExpression[
StringDelete[
ToString[Table[i, {i, 1, j}]], {"{", "}", " ", ","}]]], {h}]);
Table[g[k1, 10], {k1, FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]
Table[g[k2, 2], {k2, FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]
Table[g[k3, 10]/g[k3, 2], {k3,
FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]
Table[N[g[k4, 10]/g[k4, 2], 11], {k4,
FromDigits[Table[10^x - 1, {x, {Range[z]}}]]}]

The largest number of terms I can calculate is 8 before it crashes (?!) the program. Below the result obtained for 8 terms without using Parallelize or Compile:
EvaluationData[z = 8;
a = FromDigits[Table[10^x - 1, {x, {Range[z]}}]];
g[j_, h_] := (Take[
DigitCount[
ToExpression[
StringDelete[
ToString[Table[i, {i, 1, j}]], {"{", "}", " ", ","}]]], {h}]);
b = Flatten[Table[N[g[k4, 10]/g[k4, 2], 11], {k4, a}]];
{ListLinePlot[b,
PlotRange -> {{1, Automatic}, {Automatic, Automatic}},
LabelingFunction -> (#1 &), ImageSize -> Large], b}]

Using the result data I can make an estimate of the equation governing these fractions based on experimental (result made only by observing the first 8 terms; by guessing) and also test the value of the guessed equation at the infinite limit:
u: {1,2,3,4,5,6,7,8}
num = numerator: {0,9,189,2889,38889,488889,5888889,68888889}
dem = denominator: {1,20,300,4000,50000,600000,7000000,80000000}
z = 8;
num = (10 - 10^(1 + u) + 9*u*10^u)/90
dem = u*10^(u - 1)
sim = Simplify[num/dem]
Table[N[(-10 + 10^(1 - u) + 9*u)/(9*u), 11], {u, Range[z]}]
Limit[sim, u -> \[Infinity]]

- My attempt using Compile and Parallelize:
Now comes my attempt to improve the initial code using Parallelize and Compile to get the dots (experimental) with a better timing. I would like to be able to calculate faster and more points using the experimental code to check the data in the guessed equation. But I did not get a much better result due to my lack of experience using these commands...my attempt:
z = 8;
g = Compile[{{x, _Integer}}, Range[10^x - 1]]
EvaluationData[
Parallelize[
h[x1_] := (DigitCount[
ToExpression[
StringDelete[ToString[g[x1]], {"{", "}", " ", ","}]]])];
b = Flatten[
Table[N[Take[h[i], {10}]/Take[h[i], {2}], 11], {i, Range[z]}]];
{ListLinePlot[b,
PlotRange -> {{1, Automatic}, {Automatic, Automatic}},
LabelingFunction -> (#1 &), ImageSize -> Large], b}]

There was no significant improvement in computing time (approx. 10%) and I believe that discrete improvement was due to Parallelize and not to Compile. How do I use these commands to optimize this code and make it faster (or lighter..?)?? For I believe I did not know how to use them properly in the best way....
Thanks.