Class PieChart

java.lang.Object
com.strategyquant.tradinglib.AbstractChart
com.strategyquant.tradinglib.PieChart

public class PieChart extends AbstractChart
The Class PieChart.
  • Constructor Details

    • PieChart

      public PieChart()
      Instantiates a new pie chart.
  • Method Details

    • addValue

      public void addValue(String label, Number value, String color)
      Adds the value.
      Parameters:
      label - the label
      value - the value
      color - the color
    • getSectionByLabel

      public com.strategyquant.tradinglib.PieChart.Section getSectionByLabel(String label)
      Gets the section by label.
      Parameters:
      label - the label
      Returns:
      the section by label
    • toJSON

      public org.json.JSONObject toJSON()
      To JSON.
      Specified by:
      toJSON in class AbstractChart
      Returns:
      the JSON object