shobhit Posted June 26, 2009 Report Posted June 26, 2009 Hi all, I have read few post earlier before posting this. I have one query which was not answered yet. I am using ChartFX 7 server for java installation on tomcat. I want to show a line chart which is getting its data source from xml file which is composed in chartfx specific format. Question: If in my chartfx xml i have null values, how do i make chartfx aware of it and handle it appropriately? I just want a single API call to handle this situation instead of iterating through my data points and setting some different property for the missing value. Behavior Desired: I want the chart fx to show the null value, plot it on the graph differently from the lines so the user is intimated of a missing value. R&D Done: I tried chartCurve.getData().setInterpolateHidden(false); without success. Example of input XML: <?xml version="1.0"?> <CHARTFX> <COLUMNS> <COLUMN NAME="c0" TYPE="String" DESCRIPTION="Product"/> <COLUMN NAME="c2_c1_0" TYPE="Double" DESCRIPTION="ABC PRODUCT"/> <COLUMN NAME="c2_c1_1" TYPE="Double" DESCRIPTION="KLM PRODUCT"/> <COLUMN NAME="c2_c1_2" TYPE="Double" DESCRIPTION="XYZ PRODUCT"/></COLUMNS> <ROW c0="PRODUCT NAME" c2_c1_0="4692.5" c2_c1_1="null" c2_c1_2="4118.8"></ROW></CHARTFX> Quote
Frank Posted July 3, 2009 Report Posted July 3, 2009 Instead of setting the attribute to "null" simply remove the attribute from that row: <ROW c0="PRODUCT NAME" c2_c1_0="4692.5" c2_c1_2="4118.8"></ROW></CHARTFX> Quote
shobhit Posted July 6, 2009 Author Report Posted July 6, 2009 Yes Frank. That is the default thing which is happening currently. But omitting the null values would not allow the chart fx to plot any thing on the chart (skip the data point) . But this is NOT what I want. I know by design Chartfx is build to behave in that way, but is thier an alternate aproach I can take to some how pass some place holder in the xml which states that the data point is "null" and do the desired behaviour customized by user?? Thanks, Shobhit Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.