To place a binary proportion (of A) out of a total (A+B) on a scale from -1 to 1 centered on zero for a 50% proportion use 1-2B/(A+B).
https://www.scientificamerican.com/article/end-of-the-rainbow-new-map-scale-is-more-readable-by-people-who-are-color-blind/