Page 1 of 1
Small values don't show up
Posted: Fri Feb 09, 2007 7:59 pm
by 9239010
I've been working in an application field where values can vary from 10^20 to 10^-20 as well as negative and I encounter varying problems (automatic scaling and labeling on the axes, too many or not enough Ticks). I recently upgraded to 7.07 in hopes of resolving the issues. Because of reading a forum post
http://www.teechart.net/support/viewtop ... ht=numbers
and
http://www.teechart.net/support/viewtop ... ht=numbers
As of right now there are no ticks, labels or a visible line for a series which ranges in LeftAxis values of 1e-13 to 6e-13.
Posted: Mon Feb 12, 2007 9:50 am
by narcis
Hi Brent,
Could you please send us a simple example project we can run "as-is" to reproduce the problem here?
You can post your files at news://
www.steema.net/steema.public.attachments or at our
upload page.
Thanks in advance!
Posted: Mon Feb 12, 2007 6:24 pm
by 9239010
I've put up 2 versions. My default setup is much closer to the second version. But it becomes problematic when values start getting too much smaller than 1e-11 which seems to be some sort of limit on the maximum value.
Posted: Thu Feb 15, 2007 8:35 am
by narcis
Hi Brent,
Thanks for your examples.
The internal limit for axis range is set to 1e-10 and minimum allowed axis increment is limited by 1.0e-11.
To change those limits you should have TeeChart source code, modify them in TeEngine.pas and recompile TeeChart packages.
Another option is that you customize your axes labels using the OnGetAxisLabels event or using custom labels as shown in the
All Features\Welcome!\Axes\Labels\Custom Labels example at the features demo. You'll find the features demo at TeeChart's program group.
Also, a trick would be setting axes lables style to talMark having assigned marks style to talValue, if you don't want to display marks. The code would be something like this
Code: Select all
__fastcall TForm1::TForm1(TComponent* Owner): TForm(Owner)
{
Series1->ValueFormat="0.00e+00";
Chart1->Axes->Left->AxisValuesFormat = "0.00e+00";
for(int i=0;i<25;i++)
Series1->AddXY(i,i*pow(10,-13),AnsiString(i),clRed);
Series1->Marks->Style=smsValue;
Series1->Marks->Visible=False;
Chart1->Axes->Left->LabelStyle = talMark;
Chart1->Axes->Left->LabelsSize = 40;
}