Tip 72. Archived vector

 

Fig. 72. Archived vector

Very often initial data used for analysis are given as a few vectors. If the vectors are volumetrical (many initial points), then it is difficult to place them on a display for review and editing. One of the ways of solving this problem – “stowagethe vector in a matrix as if archived form.

The solution of one of the typical problem of regression analysis is shown in the fig. 72search of the coefficients of a function with one argument in the best way crowdedto initial points (approximation with help of least-squares method[1]). In general initial data have to be kept in two vectors X and Y, but for convenience of editing we have pushedthem in the matrix XY. With help of the program our matrix XYblossomsout two vectors X and Y, which appear in the solution of the problemin search of the coefficients a and b, incoming in the approximate equation.



[1] We have solved similar problem in the tip 52, but it was not approximation, but interpolation.