Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BarChart height issue #4795

Open
hamjabhatti10 opened this issue Jan 28, 2020 · 5 comments
Open

BarChart height issue #4795

hamjabhatti10 opened this issue Jan 28, 2020 · 5 comments

Comments

@hamjabhatti10
Copy link

I want to adjust height of bar graph according to highest bar value.
if i give height to barGraph wrap_content it shows very small bars like this

Screenshot_1580196041

And if i give fix height it draws graph with extra spaces like

Screenshot_1580196190

i want to remove this extra height

InkedScreenshot_1580196190_LI

And i want my graph like this

abccs

@kungpaogao
Copy link

Have you tried playing around with the y-axis maximums? For example:

chart.axisLeft.axisMaximum = chart.yChartMax + 1f
chart.axisRight.axisMaximum = chart.yChartMax + 1f

...or something to this effect.

@hamjabhatti10
Copy link
Author

not worked

@kungpaogao
Copy link

Do you have any code samples that you can show?

@rulogarcillan
Copy link

Im use 'com.github.PhilJay:MPAndroidChart:v3.1.0'

I have something similar in this bar chart in groups, when I only have 1 element, the bars are not drawn proportionally and are drawn below the Y axis

Screenshot_20200210-092703__01

@kungpaogao
Copy link

kungpaogao commented Feb 10, 2020

Have you tried setting axisMinimum for axisLeft and/or axisRight to 0?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants