i can hopefully generate trend line series using Function but i can not get the trend line equation like Excel.
How can i display trend line equation?
please help me...
trend equation
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi faruque,
Yes, this is possible using CalculateTrend method and something like this:
Yes, this is possible using CalculateTrend method and something like this:
Code: Select all
private void Form1_Load(object sender, EventArgs e)
{
bar1.FillSampleValues();
double m = 0;
double b = 0;
trendFunction1.CalculateTrend(trendFunction1.Series, 0, trendFunction1.Series.Count - 1, ref m, ref b);
label1.Text = "y = " + b.ToString() + "x + " + m.ToString();
}
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |