enter image description here
i have to make these chart but i not able to add color
LineDataSet actualDataSet = new LineDataSet(actualSales, “Actual Sales”);
actualDataSet.setCircleColor(Color.BLUE);
Drawable actualDrawable = ContextCompat.getDrawable(this, R.drawable.gardient_color);
actualDataSet.setDrawFilled(true);
actualDataSet.setFillDrawable(actualDrawable);
LineDataSet forecastedDataSet = new LineDataSet(forecastedSales, "Forecasted Sales");
Drawable forecastDrawable = ContextCompat.getDrawable(this, R.drawable.forecasted_color);
forecastedDataSet.setColor(Color.GREEN);
forecastedDataSet.setCircleColor(Color.GREEN);
forecastedDataSet.setDrawFilled(true);
forecastedDataSet.setFillDrawable(forecastDrawable);
forecastedDataSet.setFillAlpha(50);
i set color on different dataset but color is overlaping on another
New contributor
Aditya Singh is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.