home *** CD-ROM | disk | FTP | other *** search
/ ProfitPress Mega CDROM2 …eeware (MSDOS)(1992)(Eng) / ProfitPress-MegaCDROM2.B6I / APPS / STATISTI / TS5ST12.ZIP / STATLADR.INF < prev    next >
Encoding:
Text File  |  1990-12-23  |  11.4 KB  |  245 lines

  1. 23rd December, 1990
  2.  
  3. About TS5ST in General  (Least absolute deviation multiple regression)
  4. ======================
  5.  
  6. Contents:
  7. 1. Introduction
  8. 2. Genenral description of statladr
  9. 3. Standard errors and goodness of fit statistics
  10. 4. Release notes
  11.  
  12.  
  13. 1. INTRODUCTION
  14.  
  15. Apply question mark ? with the program call for a brief description of a
  16. program.
  17.  
  18. This package may be used and distributed freely for NON-COMMERCIAL,
  19. NON-INSTITUTIONAL, PRIVATE purposes, provided it is not changed in any way.
  20. ┌────────────────────────────────────────────────────────────────────────────┐
  21. │ For ANY other usage (such as use in a business enterprise or a university) │
  22. │ or the full scale version contact the author for a personal or a site      │
  23. │ license.                                                                   │
  24. └────────────────────────────────────────────────────────────────────────────┘
  25. Please do not distribute any part of this package separately. Uploading to
  26. BBSes is encouraged.
  27.  
  28. The registered version is strictly for the registrant only. Identical
  29. programs must NOT be running on more than one computer at a time. Site
  30. licensed programs must not be run outside the licensed site.
  31.  
  32. The programs are under development. Comments and contacts are solicited. If
  33. you have any questions, please do not hesitate to use electronic mail for
  34. communication.
  35. InterNet address: ts@chyde.uwasa.fi         (preferred)
  36. Funet address:    GADO::SALMI
  37. Bitnet address:   SALMI@FINFUN
  38. FidoNet address:  2:515/1 (Micro Maniacs Opus, To: Timo Salmi)
  39.  
  40. The author shall not be liable to the user for any direct, indirect or
  41. consequential loss arising from the use of, or inability to use, any program
  42. or file howsoever caused. No warranty is given that the programs will work
  43. under all circumstances.
  44.  
  45. Timo Salmi (in collaboration with Seppo Pynnönen)
  46. Professor of Accounting and Business Finance
  47. School of Business Studies, University of Vaasa
  48. P.O. BOX 297, SF-65101 Vaasa, Finland
  49.  
  50.  
  51. 2. GENERAL DESCRIPTION OF STATLADR (Ver. 1.1)
  52.  
  53.    STATistics: Least Absolute Deviation multiple REGRession analysis is part
  54. of the interactive statistical system by Timo Salmi. It is the fifth program
  55. in the set. The first program in the set is STATistical MEASures (STATMEAS in
  56. TS1STxx.ARC), which is intended for univariate analysis. The second program
  57. in the set is STATistics: multiple REGRession analysis (TS2STxx.ARC). The
  58. third program in the set is STATistics: TRANsformations (STATTRAN in
  59. TS3STxx.ARC), which can be used for transforming the observations, and, if
  60. necessary, also as an editor. The fourth program in the set is STATistics:
  61. Ranks and CORrelations (STATRCOR in TS4STxx.ARC).
  62.  
  63.    STATLADR includes a handy built-in help system, which can be invoked by
  64. typing ? at any interactive question. Because of this built-in help, and the
  65. interactive nature of the program's user interface, no long-winding
  66. instructions have been included. (Who reads instructions anyhow?)
  67.  
  68.    The program performs least absolute deviation (LAD) multiple regression
  69. analysis, that is, estimates the coefficients of
  70.         Y = a + b(1)X(1) + ... + b(M)X(M)
  71. from a set of observations. Whereas in ordinary least squares estimation
  72. (OLS) the sum of squared deviations between the observations and the
  73. regression equation is minimized, in LAD estimation the sum of the absolute
  74. deviations between the observations and the regression equation is minimized.
  75. Least absolute deviation multiple regression is thus equivalent to the
  76. following linear goal programming programming problem:
  77.  
  78.        n
  79.   Min Sum (Pj + Nj)
  80.       j=1
  81.  
  82.   subject to
  83.                        ┌────┬─ absolute deviation
  84.        n               │    │
  85.   a + Sum x(i,j)b(i) + Pj + Nj  = y(j)
  86.       j=1 │                       │
  87.           └─ explaining variables └─ dependent variable
  88.  
  89. STATLADR finds the estimates of the intercept [a] and the regression
  90. coefficients [b(i)] by solving this linear goal programming problem.
  91.    If the explaining variables are very similar (multicollinearity), problems
  92. tend to occur both in OLS and LAD regression estimation, and the estimates
  93. become very unstable. Further problems of significance can arise if the
  94. values of the explaining variables are of a very different scale. To test the
  95. reliability of the solution algorithm to inaccuracy indexes are computed and
  96. displayed. These are called the NON-OPTIMALITY OF THE LP SOLUTION and
  97. INACCURACY OF THE LP SOLUTION. The nearer to zero these figures, the less
  98. probability of computationally weak estimates. Although seldom reported,
  99. these problems are inherent to most (even the top commercial) statistics
  100. packages. For those in the know, the former index is the sum of positive
  101. coefficients in the optimal simplex-tableau. Mathematically they all are
  102. non-positive, but round-offs may cause some of them remain small positive
  103. numbers. The latter is based on the recalculating the optimal simplex-tableau
  104. on from the inverse of the basis matrix, and calculating the deviation of
  105. each item in the recalculated optimal simplex-tableau as compared with the
  106. original optimal simplex tableau. The inaccuracy indexes are calculated as a
  107. so called norm, that is the square root of the sum of the squared deviations.
  108. This measure is used because mathematically it represents the length of the
  109. deviation vector.
  110.  
  111.    Furthermore, STATLADR draws both low-resolution and high-resolution
  112. scatter diagrams of the data, and of the regression analysis results. The
  113. low-resolution scatter diagrams are drawn, or rather written, using ordinary
  114. ascii text, and they can thus be directed to a file. The high-resolution
  115. (graphics) scatter diagrams can only be displayed on the screen.
  116.  
  117.   The data can either be given from the keyboard or taken from a file. If the
  118. input is to be taken from a file it must first be prepared with some editor,
  119. or some word processor which includes an option for preparing ordinary ascii
  120. text. (Also STATTRAN can be used for this purpose.)
  121.    The data is given to the program in the following format:
  122.  
  123.        X1 X2 X3                    !variable names (! denotes a comment)
  124.        3.56 6.32 -1.73
  125.        5.12 -4.21 9.18
  126.        14.2 5.11 0.31
  127.        END                         !END is optional in a file
  128.  
  129. A missing item in an observation is marked by a hash (#). E.g. if the first
  130. item of the second observation were missing, the observation should be
  131. written as  # -4.21 9.18
  132.  
  133.    The items in an observation can be separated with blanks, as in the above,
  134. or with commas (,) e.g. 5.12,-4.21,9.18. The number of the intervening
  135. blanks is irrelevant, and can be customized for increased readability. Thus
  136. e.g. 5.12 -4.21 9.18 and    5.12    -4.21     9.18    are equivalent.
  137.    A row can be continued using an ampersand (&). E.g. the variables could
  138. be given as
  139.        X1 X2 &
  140.        X3
  141. Alternatively, * or \ can be used instead of & as the continuation marker.
  142.  
  143.    Comments can be added to the input data. If ! appears on a line all text
  144. after ! will be considered as a comment.
  145.    A header can be entered on each page if output is directed to a file.
  146. To accomplish this start the very first line on the input file with a
  147. double exclamation mark (!!) and the rest of the line will be used as the
  148. header. Thus !! indicates a header, a single ! an ordinary comment.
  149.  
  150.    The maximum number of variables is 25. The maximum number of observations
  151. is 100 (for each variable). The public domain version, however, sets the
  152. limits at 4 and 50 respectively.
  153.  
  154.  
  155. 3. STANDARD ERRORS AND GOODNESS OF FIT STATISTICS
  156.  
  157.    This chapter describes the formulas of the new features that were added
  158. to statladr.exe in the updated version 1.1. This chapter has been written by
  159. Seppo Pynnönen.
  160.  
  161.    The standard errors of the estimates of the regression coefficients are
  162. calculated as
  163.  
  164.                                jj      
  165.                std(b) = s * X'X  ,
  166.  
  167.  
  168. where X is the n x (M+1) data matrix of x variables with vector of ones in
  169.                      jj
  170. the first column, X'X   denotes the j:th diagonal element of the inverse of
  171. the X'X-matrix and the prime (') stands for the transpose, s is an estimate
  172. of the standard error of the residual terms of the regression model. (n
  173. stands for the number of observations, and M for the number of explanatory
  174. variables.) Here we have defined the standard error (s) of the residuals as
  175.  
  176.                    1
  177.              s = ------,
  178.                   2f(m)
  179.  
  180. where
  181.                         2d
  182.           f(m) = -------------------
  183.                  n(e      - e      )
  184.                     (m+d)     (m-d)
  185.  
  186. with d defined below, e    denote the ordered residuals, and m is the median
  187.                        (j)
  188. point of the ordered residuals. The parameter d depends on the sample size.
  189. In the literature it is suggested that it should be kept small. Here we have
  190. adopted the following convention and defined d as
  191.  
  192.              d = max[1, n'/6],
  193.  
  194. where n' = n-M-1 (i.e., the number of residuals which are not zero by
  195. definition due to the LP-solution).
  196.  
  197.    The t-values are defined as b(j)/std(b) (j = 0, 1, ..., M, with b(0),
  198. the intercept term), where std(b) is defined in the previous paragraphs.
  199.  
  200.    The LAD coefficient of determination is defined as
  201.  
  202.                                               Sum |e(i)|
  203.                                                i
  204.    LAD COEFFICIENT OF DETERMINATION = 1 - ------------------
  205.                                           Sum |y(i) - Md(y)|
  206.                                            i
  207.  
  208. (cf. the R-square in the OLS-regression), where Md(y) is the median of y.
  209.  
  210.  
  211. 4. RELEASE NOTES
  212.  
  213.    Version 1.1: The most important inprovements were descibed in the previous
  214. chapter.
  215.    Furthermore, I have corrected a bug, which decreased the maximum capacity
  216. of the program by one observation.
  217.    Some stytistic minor imporvements have also been made.
  218.  
  219.    Version 1.2: Several improvements to the nuts and bolts of the user
  220. interface.
  221.    The new usage of the call is
  222. PROGNAME [/h(elp)] [/iInputFileName] [/oOutputFileName] [/cColumnsPerRow]
  223. (the /c option, which regulates the width of the output, is for registered
  224. versions, only). If you use the /i switch, it stuffs the InputFileName into
  225. the appropriate recall buffer. This means that when the program asks you for
  226. the input file name, you can invoke the input file name just by pressing the
  227. CursorUp key. (The same goes for the /o switch, respectively.) This is very
  228. convenient, if you use the program many times successively making small
  229. changes in your data in between. (This assumes, of course, that you have a
  230. command line editor like DOSEDIT or CED to recall previous MsDos commands.
  231. These common shareware programs can be obtained from any well-stocked BBS or
  232. FTP site.)
  233.    The printer readiness test has been rewritten to be more general. The
  234. earlier test failed for some printers, because the codes the printers send
  235. when they are offline are not standardized.
  236.    The "file exists, overwrite?" question is no more asked when the output
  237. file is prn, in other words when the output is directed to the printer.
  238.    The user has now a choice of a left margin from 0 to 20 blanks when output
  239. is directed to the printer.
  240.    The user has now a choice between formfeed and four blank lines to start
  241. each new page of output.
  242.    When an input file is not found, the user is given the choice of listing a
  243. directory. The directory routine has been rewritten.
  244.    The file ready message now also includes the file side besides the name.
  245.