Profile Picture

How to set the function line position

Posted By bargitta chen 13 Years Ago
Author
Message
Nevron Support
Posted 13 Years Ago
View Quick Profile
Supreme Being

Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)

Group: Forum Members
Last Active: Last Week
Posts: 3,054, Visits: 4,009

Hi Bargitta,

1. As the attachment shows(please refer to Q1), currently I use NFunctionCalculator to draw some lines. However, when it comes to the clustered bar, the default line position especially the point location is not suitable. How can I map the line position to the corresponding bar series?

2. Does nevron support the function of drawing a linear trend line of bars as the excel does? If so, how can I access this function?

3. If I want to get the X coordinate of each bar center, especially for clustered bars, how to calculate it?

1 & 2 actually are related - you can get the x coordinate using the following formula in pseudo code

clusterWidth = (1 * barPercentWidthOfCluster) / 100.0
barWidth = clusterWidth / numberOfBarsInCluster

barX = barIndex + 0.5 - clusterWidth / 2.0 + barWidth * barIndexInCluster + barWidth / 2.0

in general the idea is to find the center coordinate:

barIndex + 0.5

then move to the beginning of the cluster:

barIndex + 0.5 - clusterWidth / 2.0

then advance to the to the bar center

barX = barIndex + 0.5 - clusterWidth / 2.0 + barWidth * barIndexInCluster + barWidth / 2.0


 



Best Regards,
Nevron Support Team



bargitta chen
questionmark Posted 13 Years Ago
View Quick Profile
Junior Member

Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)Junior Member (18 reputation)

Group: Forum Members
Last Active: 12 Years Ago
Posts: 18, Visits: 1
Dear experts,

I have several questions about bar chart and line.

1. As the attachment shows(please refer to Q1), currently I use NFunctionCalculator to draw some lines. However, when it comes to the clustered bar, the default line position especially the point location is not suitable. How can I map the line position to the corresponding bar series?

2. Does nevron support the function of drawing a linear trend line of bars as the excel does? If so, how can I access this function?

3. If I want to get the X coordinate of each bar center, especially for clustered bars, how to calculate it?

Thank you for your consideration.

Looking forward to your reply!

Attachments
LinePosition.jpg (95 views, 69.00 KB)


Similar Topics


Reading This Topic