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

Way to show "no data available" for a given point? Options · View
mattkranzler
#1 Posted : Wednesday, March 30, 2011 11:44:47 PM
Rank: Newbie

Groups: Registered

Joined: 3/25/2011
Posts: 3
Location: North Dakota
Hi, I am currently using the trial of the aiCharts for Android, and we are planning on purchasing the subscription, however I have a question. We are graphing interval readings for a given year/month/week/day and we need the x-axis to always contain a certain range (for Year it would be Jan/Feb/March/etc...). For point we will have a double value which plots to a date. The problem is that there will be times when a certain date we do not have data for and 0.00 does not mean the same as no data available. Is there a way we can represent this on the graph? Specifically via shading the background of the chart between the points we don't have? Or is there a better way anyone can recommend?

Any help is appreciated! Thanks!
Baydalka Volodymyr
#2 Posted : Thursday, March 31, 2011 1:56:57 PM
Rank: Developers Team


Groups: Registered, Administrators

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

There is no some special API to show "no data available" for a point. However you may use ChartAxisStripLine to shade part of chart. Example :
Code:

ChartAxisStripLine stripLine = new ChartAxisStripLine();

stripLine.setStart(1);
stripLine.setEnd(3);

chartArea.getDefaultXAxis().getStripLines().add(stripLine);


Also, you may change point color for bar--like types. Example :
Code:

ChartPoint point = new ChartPoint(x, y);

if(hasValue)
{
  point.setBackColor(Color.GRAY);
}
else
{
  point.setBackColor(null); // reset color
}


Best regards,
Volodymyr Baydalka
Andriod development and support team
mattkranzler
#3 Posted : Thursday, March 31, 2011 4:52:38 PM
Rank: Newbie

Groups: Registered

Joined: 3/25/2011
Posts: 3
Location: North Dakota
Baydalka Volodymyr wrote:
Hi,

There is no some special API to show "no data available" for a point. However you may use ChartAxisStripLine to shade part of chart. Example :
Code:

ChartAxisStripLine stripLine = new ChartAxisStripLine();

stripLine.setStart(1);
stripLine.setEnd(3);

chartArea.getDefaultXAxis().getStripLines().add(stripLine);


Also, you may change point color for bar--like types. Example :
Code:

ChartPoint point = new ChartPoint(x, y);

if(hasValue)
{
  point.setBackColor(Color.GRAY);
}
else
{
  point.setBackColor(null); // reset color
}


Best regards,


Thanks for the response. It sounds like the ChartAxisStripLine may be what I want, however it isn't showing up at all on my graph. I copied the code you gave me and set the background color to blue on the strip line and nothing shows up on the x-axis. Is there anything else I need to do?

Also, is there any way I can change the label color for individual labels on the x-axis? So maybe color Jan, Feb red if I don't have data for those months and the rest black?

Thanks.
Baydalka Volodymyr
#4 Posted : Friday, April 01, 2011 11:58:35 AM
Rank: Developers Team


Groups: Registered, Administrators

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

Try to change setStart/setEnd values. Make note that values should be in visible range.

There is no ability to set color or font size for individual labels.

Best regards,
Volodymyr Baydalka
Andriod development and support team
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.