A fast way to compute Least Squares Teo Zhi Shen Anderson Serangoon Junior College
Least squares and Linear regression Used in the study of relationships between variables X and Y to : 1. Determine how strong the relationship is between the 2 variables X and Y 2. Predict effects on Y caused by changes in X 3. Predict a trend between X and Y
Method of Least Squares Minimises the squares of the differences between the data points and modelled equation. Scatter plot
Rise of Big Data More Longer computation Increasingly information times + Reduced large data sets generated efficiency
Applications of Least Square Used in :
The Two point method The new two point method aims to form the line of best fit based on 2 points. 1.Geometric Centre of the scatter plot 2.” Centre of Mass” of the scatter plot
Improvements 2 Point Method Current Method - Simpler - Contains complex computational steps operations like partial derivatives - More operations - Lesser operations
Aims and Objectives To determine whether the Two Point Method is indeed faster and more efficient than the current method for computing least square.
Computation Time Through the use of Python, the computation time for both methods can be compared with one another to confirm that the 2 point method is indeed faster.
Comparing Computing Times
Trends For smaller sets of data, the current method is faster. However for larger sets, the 2 point method is faster.
Conclusion The new Two point method is indeed faster in calculating large data sets. However, both methods are still vulnerable to outlier values. Additionally , the new Two Point method can only be used to improve the efficiency of linear regression but not non-linear data sets.
Recommend
More recommend