title: Is there a way to use plot number/identifier in a vega expression in vega repeat plot?
body: <p>I would like to use vega-lite to produce a small multiples chart that show a progression through a series of states. Each individual plot contains the same set of geographic points that I wish to color according to a third variable depending on which plot it is in the series. </p>
  
  <p>Is it possible, using vega-lite, to color the points according to a rule based on the position of a particular multiple within the series? </p>
  
  <p>For example, in multiple 1 I want to color all points that have a value == 1 red, and the rest gray; in multiple 2 I want to color all points that have a value == 2 red and the rest gray; etc etc</p>
  
  <p>So far I have tried setting up a <code>repeat</code> chart in vega (<code>facet</code> is no good because I need all of the data in each plot) and then to use a condition on the color encoding:</p>
  
  <pre><code>"color": {
          "condition": {
            "test": "datum.rdb == ???",
            "value": "#ff0000"
          },
       "value":"#aaaaaa" // grey if condition not met
  </code></pre>
  
  <p>But I don't know what <code>???</code> should be in order to get the number or identifier of each plot within the multiple.</p>