﻿ 用SAS MACRO程序建立多项式模型与变量筛选

# 用SAS MACRO程序建立多项式模型与变量筛选Using SAS MACRO Programs to Build a Polynomial Model and Do the Selection of Variables

Abstract: The purpose of this paper is trying to provide a useful solution to build a polynomial model. In the past years, there are a few applications on polynomial model; the reason is that it is difficult to create a large number of variables. For example, if you want to build a 3rd order polynomial with 5 variables, then you need 55 variables. If the variables increase to 18, then a 2nd order polynomial model will need 189 variables. It is far away from our ability. That is the reason why I wrote the following programs. There are 3 major reasons that I would like to deal with the polynomial model: 1) if the unknown model was smooth plan curve, then a polynomial model can provide an acceptable approximation. This can be easily seen from the Taylor’s polynomial; 2) as long as we have enough observations, then using a high order polynomial model can solve the unfitted problems; 3) it can avoid deleting important variables from the selection steps, since it is not easy to remove a variable completely from the model because there are too many cross product terms shown in the model. This paper will provide 2 major SAS MACRO programs, %Homopoly and %Model_Selection. The first program is used to generate a polynomial model and the next one will provide summarized result tables similar to the Table 11.8 of Montgomery including the information of the models and necessary statistics. Users can easily apply to do the further analysis. To write those programs, I also wrote another 20 SAS MACRO programs which can be downloaded from the web-site http://tsp.ec.tku.edu.tw/QuickPlace/054569qp/Main. nsf/h_Toc/BADD7D0BFF0904A1482576D300229684/?OpenDocument. Please follow the in-struction given by the readme.txt file.

 Montgomery, D.C., Peck, E.A. and Vining, G.G. (2006) Introduction to linear regression analysis. 4th Edition, Willey, New York.

 Wang, K.-J. (2013) Notes for regression analysis. Tamkang University, New Taipei.

Top