LineGraph Using Android plot - android

I have create simple line chart using Android Plot library.
what i want to do is:
set X range Upto Seven results(I have done this).
and set max value of Y is 100.
currently it takes max value of array as max Y value.
i want like this:
any suggetion?
Thanks...

I think the answer is that you are confusing the number of data points with the maximum value of the axis. Your x-axis is just the number of data points, it has not value as such. The y-axis will contain the same number of points - however I believe you want to set the maximum value of the y-axis to 100 because it is a percentage. You can do this by using setRangeBoundaries

Related

Androind linechart displaying X amount of values per Range

My questions is that I would like to display X amount of values per range so lets say I have range of 1000 values and I would like to display only 100 of them so It would make some sort of averages between them and display them is that possible ?

Make limit line always visible on mpandroidchart

I am making an app which retrieves data from a database and shows it on a barchart. I have defined a limit line using the provided methods at 30f (on the Y axis).
The problem is, that I want that limit line to be always shown and it only becomes visible when one of the Graph's Bars raises above that value (30f).
Is there a way to always show it?
I have tried with the zoom functions with no luck.
Modify the YAxis display range to your needs: https://github.com/PhilJay/MPAndroidChart/wiki/YAxis-(YLabels)
Especially those methods should help:
setAxisMaxValue(float max): Set a custom maximum value for this axis. If set, this value will not be calculated automatically depending on the provided data.
setAxisMinValue(float min): Set a custom minimum value for this axis. If set, this value will not be calculated automatically depending on the provided data.

How to set maximum x-axis value for HorizontalBarChart?

I am working with the MPAndroidChart library and I am trying to produce a Horizontal Bar Chart with only one item in the data set. The issue I am running into is setting the max value for the x-axis. I would like to say the max X value is 1000 and if the value in the data set is 500 then the bar chart would only go 1/2 way across the screen. My issue is that I can't seem to find a way to set the max value of the x axis for the Horizontal Bar Chart in the MPAndroidChart library.
I know this is kind of misleading, but for the HorizontalBarChart, this needs to be set via the y-axis :-)
Here is the full documentation of the YAxis.
Check out the setAxisMaxValue(float max) method.

AChartEngine y-axis number range

I'm using AChartEngine in my Android app.
In the line graph the default value of the difference between numbers on
y-axis numbers is always 500 or higher. How can I change this number?
For Example:
the values on the left side start at 500 then 1000 then 1500 and I would like to set the
first number to for example 100, then 200 etc. I can't find a good method in the library.
Kind regards!
Try this in your XYMultipleSeriesRenderer .. It's not enough means increase the value...
renderer.setYLabels(10);

Intersection of GridLines and line chart y-axis value

I am able to display the AChartEngine's TimeChartView to user, but when the graph renders, the grid lines (vertical - set by showGridLines(true)) and the line drawn on graph to display corresponding y-axis value (time in secs) against the dates on x-axis don't intersect with each other.
The y-axis value pt shows up either before the x-axis value or after it, but not exactly on it.
Please suggest, if there's any achartengine property which needs to be set to get this done / any other thing that needs to be done for getting this done.
Thanks
Omkar Ghaisas
Sample Image --
As can be seen, the points marked with ovals don't coincide with the vertical grid lines and with x axis values, but start before that. E.g the first y value for 7200 should start at vertical line of 02/03/2012, but instead starts before that. Similarly for all other data points.
This was fixed in the AChartEngine SVN.
Please see this for extra information.

Categories

Resources