title: MPAndroidChart Legend with different shapes (forms)
body: <p>I am using <a href="https://github.com/PhilJay/MPAndroidChart" rel="nofollow noreferrer">MPAndroidChart</a> and have the need to plot a number of datasets using ScatterChart. As the number of datasets is dynamic, I used a logic that creates a combination of color and shape for each dataset. The resultant chart looks like this. As you can see, in this example, there are ten datasets, each represented by a unique Shape+Color combination. The problem is with the legend shapes. How do I change the legend shapes to match with the dataset shapes?</p>
  
  <p><strong>Chart</strong>:
  <a href="https://i.stack.imgur.com/vOmjP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vOmjP.png" alt="enter image description here"></a></p>
  
  <p><strong>Source Code</strong>:</p>
  
  <pre><code>        private static final int SCATTER_SHAPES_MOD = 4; //there are four shapes
          private static final int SCATTER_COLOR_MOD = 5; //there are five colors
          for (int i=0; i &lt; dataSeries.size(); i++) {
              ScatterDataSet set = new ScatterDataSet(dataSeries.get(i), choiceArray[i]);
              set.setScatterShape(ScatterShapeArray[i % SCATTER_SHAPES_MOD]);
              set.setColor(ColorTemplate.COLORFUL_COLORS[i % SCATTER_COLOR_MOD]);
              set.setScatterShapeSize(10f);
              set.setDrawValues(false); // Hide data labels
              dataSets.add(set); // add the dataset
          }
          if (dataSeries.size() &gt; 0) {
              data = new ScatterData(xVals, dataSets);
              // Set chart data
              chart.setData(data);
          }
  </code></pre>