whitespace COMPANY whitespace SERVICES whitespace PRODUCTS whitespace PURCHASE whitespace SUPPORT whitespace CONTACTS whitespace Home whitespace Contact Us whitespace Site Map whitespace
whitespace
SUPPORT
whitespace
FORUM
whitespace
FAQS
whitespace
SUBSCRIPTION
whitespace
REQUEST ON-LINE
whitespace
whitespace

Technical Support Forum

Welcome Guest Search | Active Topics | Log In | Register

Column chart label shows "NaN" for negative values less than zero Options · View
aallllaann
#1 Posted : Tuesday, May 24, 2011 9:34:11 AM
Rank: Member

Groups: Registered

Joined: 3/8/2011
Posts: 11
I edited the ColumnSample sample project included on the aicharts.android.1.5.0.3.zip file

original code:
Code:
String[] labels = {"Boxing", "Kickboxing", "Karate", "Street fighting", "RUN!!!"};
double[] efficiency = { 35, 40, 30, 50, 100 };


changed to:
Code:
String[] labels = {"Boxing", "Kickboxing", "Karate", "Street fighting", "RUN!!!"};
double[] efficiency = { 35, -0.1, 30, 50, 100 };
series.setShowLabel(true);



when i changed 40 to -0.1, the graph displays NaN instead of -0.1


is this a bug? any fixes/workaround? thanks!



Baydalka Volodymyr
#2 Posted : Tuesday, May 24, 2011 12:20:25 PM
Rank: Developers Team


Groups: Registered, Administrators

Joined: 7/28/2009
Posts: 447
Hi,

Thank you for bug report. It's look like the rounding is failed. To workaround this you may
1) set label manually - series.getPoints().get(pointIndex).setLabel("-0.1");
2) setup your format to avoid default rounding - series.setLabelFormat("{YVALUE,#.##}");

Best regards,
Volodymyr Baydalka
Andriod development and support team
aallllaann
#3 Posted : Tuesday, May 24, 2011 1:08:37 PM
Rank: Member

Groups: Registered

Joined: 3/8/2011
Posts: 11
ok I fixed it. thanks for the fast reply!
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Company | Services | Practices | Technologies | Career | Contacts | Privacy
© 2005-2016 ArtfulBits. All rights reserved.