Recent changes to 1: Variance Chart Legend No Show, Truncate, or Repeating Digithttp://sourceforge.net/p/sparklinesforxl/bugs/1/Recent changes to 1: Variance Chart Legend No Show, Truncate, or Repeating DigitenThu, 30 Oct 2008 21:19:01 -0000Variance Chart Legend No Show, Truncate, or Repeating Digithttp://sourceforge.net/p/sparklinesforxl/bugs/1/<div class="markdown_content"><p>Sparklines for Excel Chart Module: <br />
Variance Chart</p>
<p>Environment:<br />
Windows XP – Excel 2003 SP 3</p>
<p>Problem Description:<br />
Applies to Legend Usage for Variance Chart</p>
<p>When passing values to the varichart function, if the length of the underlying value calculated is greater in length then the size of the bar of variance, the value will be truncated or will just not appear.</p>
<p>In addition, if the calculation of the variance has a repeating decimal it will repeat the digit to the end of the variance bar never displaying the decimal point.</p>
<p>Reproduction Steps<br />
Set the column width to 25 and put the following formulas into the column.</p>
<p>Repeating Digit Issue for Positive Variance:<br />
=varichart(280/150-1,,,,,,TRUE)</p>
<p>Repeating Digit Issue for Negative Variance:<br />
=varichart(35/150-1,,,,,,TRUE)</p>
<p>Truncation of Positive Values<br />
=varichart(171/150-1,,,,,,TRUE)</p>
<p>Not Showing Any Legend Value<br />
=varichart(155/150-1,,,,,,TRUE)</p>
<p>Expected Behavior<br />
When invoking the Legend, some value should always be printed in the variance chart. Today this does not seem to happen do to two conditions:</p>
<p>1. The function accepting the value for the legend does not limit the number of significant digits thus the entire chart is full with repeating values when a format like 1/ 3 is used.</p>
<p>2. The function is trying to print the value inside of the bar chart thus if the value is too small to be represented on the bar chart it will not actually show.</p>
<p>Possible Fixes<br />
Alternative 1:<br />
Limit the number of significant digits that can be passed to the variance function by recasting the value and instead of printing the legend inside the bar, print the legend at the max or min point thus a value will always print.</p>
<p>Alternative 2:<br />
Limit the number of significant digits that can be passed to the variance function by recasting the value and instead of printing the legend inside the bar, reserve space on the left hand side of the chart to print the legend. (Note: this alternative would then need a corresponding change in the function InvScaleline and Scaleline in order to accommodate a legend to the left hand side of a variance chart. Alternative 1 would not need this change.)</p></div>GrantThu, 30 Oct 2008 21:19:01 -0000http://sourceforge.netf1742aa524c32d367d086954d7658abcaa2cf0ef