什么是一元线性回归:
https://blog.csdn.net/cx943024256/article/details/79124113
https://blog.csdn.net/Moxiaoaijing/article/details/81109220
https://blog.csdn.net/hongbin_xu/article/details/77102810
第三篇的比较好点吧 但他在一元线性回归的w推导出错了
我在下面的代码已经改正过来
3个方法分别对应三篇文章表达的计算方法
C#代码实现:
using System;
using System.Collections.Generic;
namespace LinearRegression
{
class Program
{
static void Main(string[] args)
{
List<Point> _PList = new List<Point>();
_PList.Add(new Point(1, 3.09));
_PList.Add(new Point(2, 5.06));
_PList.Add(new Point(3, 7.03));
_PList.Add(new Point(4, 9.12));
_PList.Add(new