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

when dataset value is increases then the graph value is misplace . and i am showing three bar in one group. and also show the integer value in particular bar above. #2938

Closed
Raj14737 opened this issue Nov 1, 2017 · 8 comments

Comments

@Raj14737
Copy link

Raj14737 commented Nov 1, 2017

No description provided.

@Raj14737 Raj14737 changed the title when dataset value is increases then the graph value is misplace . and i am showing three bar in one group. when dataset value is increases then the graph value is misplace . and i am showing three bar in one group. and also show the integer value in particular bar above. Nov 1, 2017
@liuxuan30
Copy link
Member

liuxuan30 commented Nov 6, 2017

can barely understand. give more details and we will update.
if you change your data set, call chartData.notifyDataChanged
for drawing values, check out ChartsDemo multiple bar chart.

@Raj14737
Copy link
Author

Raj14737 commented Nov 6, 2017

let take an example , if i have an data set {"jan", "feb" ,"mar" ,"apr" , "may", "june"}. and i set the graph as look and feel for setting 3 bar as a group.

2 - if data set value {"jan", "feb" ,"mar","apr" ,"may" ,"june" ,"july" ,"aug" ,"sep"} , then my whole view of graph is disturbed , and all bars are overlaped .

@liuxuan30
Copy link
Member

liuxuan30 commented Nov 10, 2017

give a screenshot. take a look at multiple bar chart btw. make sure bar space, group space, bar width formula sums to 1.0

    float groupSpace = 0.08f;
    float barSpace = 0.03f;
    float barWidth = 0.2f;
    // (0.2 + 0.03) * setCount + 0.08 = 1.00 -> interval per "group"

@Raj14737
Copy link
Author

screen shot 2017-11-10 at 10 11 51 am

this graph comes when data set value comes more than - 4

@Raj14737
Copy link
Author

Raj14737 commented Nov 10, 2017

screen shot 2017-11-10 at 10 13 04 am

this graph come when dataset value come - 4,

        let groupSpace = 0.16
        let barSpace = 0.05
        let barWidth = 0.23

startPoint = 0

cell.viewSummaryBarChart.xAxis.axisMaximum = Double(startPoint) + 1.6 * Double(groupCount)

and gropucount -- 4

@Raj14737
Copy link
Author

screen shot 2017-11-10 at 10 22 23 am

this graph comes - when i used this

let groupSpace = 0.16
let barSpace = 0.05
let barWidth = 0.23
startPoint = 0

and when i used this method to found groupwidth -

let group_space = chartData.groupWidth(groupSpace: groupSpace, barSpace: barSpace)

@Raj14737
Copy link
Author

Raj14737 commented Nov 10, 2017

i want to that it set perfectally , it dont be depended how many dataset it comes . either it be 4 or it be 6 .

@liuxuan30
Copy link
Member

I barely understand. check out charts demo, play with it first.

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

2 participants