Ah ok you want a transformation where ratios remain symmetric, meaning:
transform(a) / transform(b) == transform(b) / transform(a)
That's not possible with log or any monotonic function, because:
log(a)/log(b) != log(b)/log(a)
And no asymmetric function (like log or exp) will ever preserve a/b == b/a under transformation.
Since perfect symmetry in a/b == b/a under transformation is impossible, here are options depending on what you're trying to do:
1. Use Log Difference Instead of Ratio
Instead of comparing a/b, use:
log(a) - log(b)
This is symmetric in the sense that:
log(a) - log(b) == -(log(b) - log(a))
That’s how log returns are used: they're additive and symmetric in change, not ratio.
2. Use Geometric Mean Normalization
If you want a “centered” comparison between a and b, try:
ratio = log(a / b)
normalized = ratio / abs(ratio) * abs(log(a / b))
Or define:
sym_ratio = abs(log(a / b))
This gives a “distance” in log space, symmetric between a and b.
3. Custom Transformation
You could define a transformation like:
f(x) = log(x / M)
Where M is a midpoint or geometric mean reference. Then:
f(a) = log(a / M)
f(b) = log(b / M)
Now:
f(a) - f(b) = log(a / b)
This isn’t symmetric directly in the ratio sense, but differences are meaningful and centered.
TL;DR :
want log chart with only positives AND >symmetric ratios (a/b == b/a)
not possible. log(a/b) ≠ log(b/a), and no >function makes a/b == b/a for all a≠b
try using log(a) - log(b) instead, it’s >symmetric in direction (flip sign), or use >abs(log(a / b)) as a "distance"