title: How to select elements according to an attribute(fill color) in D3.js with SelectAll
body: <p>I have sets of circles on a map like 10 red circles, 10 blue circles, 10 green circles. How can i select only red circles using d3 selectAll or select? </p>
  
  <p>Or is there any other methods than that?</p>
  
  <p>the color has been given like this(as the value of "fill" in "style" attribute,</p>
  
  <pre><code>feature = g.selectAll("circle")
      .data(data)
      .enter().append("circle")
      .attr("id", function (d) {
      return d.ArtistID + d.FollowerID;
  })
      .style("stroke", "black")
      .style("opacity", .6)
      .style("fill", function (d) {
      if (d.ArtistID == 1) {
          return "red"
      } else if (d.ArtistID == 2) {
          return "blue"
      } else {
          return "green"
      };
  })
      .attr("r", 10);
  </code></pre>
  
  <p>so, the circles will be drawn like this,</p>
  
  <pre><code>&lt;circle id="10" r="10" transform="translate(695,236)" style="stroke: rgb(0, 0, 0); opacity: 0.6; fill: rgb(255, 255, 0);"&gt;&lt;/circle&gt;
  </code></pre>
  
  <p>I want to select the circles of red color. Cam somebody help?</p>
  
  <p>Thanks in Advance.</p>