title: Google Sheets Conditional Formatting of another cell based on variable values
body: <p>I have rows that include various totals of either 5, 10 or 12. I also have checkboxes that add up to a total of 12, and a cell value for each row that calculates the difference to reveal how many are left.</p>
  
  <p>I'm wanting the last result cells to show colours from red to yellow to green that is independently reliant on the first cells value to show a specific shade of green/yellow/red. I'm only able to select a colour based on the single columns/cells value and not the value of another column/cell. Is this even possible?</p>
  
  <p>I've run through a number of examples given on google and answers based on similar questions, but nothing seems to solve this specific situation.</p>
  
  <h2>This is what I'm expecting to happen: Green Yellow Red</h2>
  
  <p>For Green Total:</p>
  
  <pre><code>Row 0:  Column A:         | Column B:     | Column C:
  
  Row 1:  Classes Available | Classes Left  | Colour
  
  Row 2:  10                | 10            | Green
  
  Row 3:  5                 | 5             | Green
  
  Row 4:  12                | 12            | Green
  </code></pre>
  
  <p>For Variable Total:</p>
  
  <pre><code>Row 0:  Column A:         | Column B:     | Column C:
  
  Row 1:  Classes Available | Classes Left  | Colour
  
  Row 2:  10                | 5             | Yellow
  
  Row 3:  5                 | 4             | Green
  
  Row 4:  12                | 3             | Red
  </code></pre>
  
  <p>For Red Total:</p>
  
  <pre><code>Row 0:  Column A:         | Column B:     | Column C:
  
  Row 1:  Classes Available | Classes Left  | Colour
  
  Row 2:  10                | 0             | Red
  
  Row 3:  5                 | 1             | Red
  
  Row 4:  12                | 2             | Red
  </code></pre>
  
  <p>Basically: If we're looking at 3 cells next to each other in ABC, then if B is the variable, and A is the total value, then C should show the colour based on how equal B is to A for Green, or how much lower the value of B is to A for Yellow to Red.</p>