Chart showing data which is not provided in Dataset
I am using MPAndroidChart to plot some Market Data in my android app. I am storing the Time as float for X axis data & Price as float in Y axis data. <EXAMPLE INPUT DATA> 0057.0 , 247.25 0058.0 , 247.3 0059.0 , 247.25 0100.0 , 247.3 0101.0 , 247.4 0102.0 , 247.45 0103.0 , 247.55 0104.0 , 247.6
I am using AxisValueFormatter to modify the above data into proper format
Here is my sample code :
y.setLabelCount(5, false);
ArrayList<Entry> chartDataVals = new ArrayList<Entry>();
chartDataVals.add(new Entry(<**EXAMPLE INPUT DATA**>));
lineDataSet = new LineDataSet(chartDataVals, "Market Data Set");
LineData data = new LineData(lineDataSet);
lineChart.setData(data);
My problem is, the GRAPH is plotting for values that I haven't even provided in my dataset.
**Please see attached screenshots

**.
X axis is showing a value "00:80", which wasn't there in my input dataset. I am not able to debug where this value is coming from. Also, the MarkerView doesn't highlight any DATA when scrolled between the region from "00:60" - "01:00".
Can anyone suggest a solution for this ?
I'm assuming you're looking to make a gap in the data?
It seems like there is no built in way to do this right now, you are going to have to detect these gaps by setting some threshold(whatever you think is reasonable). If the x values exceed that threshold then make a new data set.
The marker is not highlighting the data because there is no data there, but the library still connects the dots between the (0059.0, 247.25) and (0100.0, 247.3) data points.
Thanks for your input. I managed to figure out another way to manipulate the input dataset.