==========<< プログラム1 >>===================================================== freq a; smpl 1993 2003; load income cons cpi kokusai; . . 97.9 . 470862.4 270932.1 98.6 4.399 480323.5 276086.4 98.5 3.373 496822.2 282897.1 98.6 3.107 505622.6 284989.3 100.4 2.355 500329.1 284352.6 101.0 1.571 499651.0 284242.7 100.7 1.759 511569.1 285750.1 100.0 1.735 512608.5 288777.0 99.3 1.322 511056.0 290356.4 98.4 1.237 517727.3 291004.5 98.1 1.013; print income cons cpi kokusai; smpl 1994 2003; olsq cons c income; olsq cons c income kokusai; pcpi=100*(cpi-cpi(-1))/cpi(-1); olsq cons c income kokusai pcpi; ==========<< プログラム2: データの取り込み(テキスト・ファイルの場合) >>========= freq a; smpl 1993 2003; load(file='cons2.txt') income cons cpi kokusai; print income cons cpi kokusai; smpl 1994 2003; olsq cons c income; olsq cons c income kokusai; pcpi=100*(cpi-cpi(-1))/cpi(-1); olsq cons c income kokusai pcpi; ==========<< プログラム3: データの取り込み(Excelファイルの場合) >>============== freq a; smpl 1993 2003; load(file='cons2.xls') income cons cpi kokusai; print income cons cpi kokusai; smpl 1994 2003; olsq cons c income; olsq cons c income kokusai; pcpi=100*(cpi-cpi(-1))/cpi(-1); olsq cons c income kokusai pcpi; ==========<< プログラム1の出力結果 >>=========================================== TSP Version 4.5 (06/20/99) Windows32 4MB Copyright (C) 1999 TSP International ALL RIGHTS RESERVED 05/23/05 10:16AM In case of questions or problems, see your local TSP consultant or send a description of the problem and the associated TSP output to: TSP International P.O. Box 61015, Station A Palo Alto, CA 94306 USA PROGRAM LINE ****************************************************************** | 1 freq a; | 2 smpl 1993 2003; | 3 load income cons cpi kokusai; | 3 . . 97.9 . | 3 470862.4 270932.1 98.6 4.399 | 3 480323.5 276086.4 98.5 3.373 | 3 496822.2 282897.1 98.6 3.107 | 3 505622.6 284989.3 100.4 2.355 | 3 500329.1 284352.6 101.0 1.571 | 3 499651.0 284242.7 100.7 1.759 | 3 511569.1 285750.1 100.0 1.735 | 3 512608.5 288777.0 99.3 1.322 | 3 511056.0 290356.4 98.4 1.237 | 3 517727.3 291004.5 98.1 1.013; | 4 print income cons cpi kokusai; | 5 smpl 1994 2003; | 6 olsq cons c income; | 7 olsq cons c income kokusai; | 8 pcpi=100*(cpi-cpi(-1))/cpi(-1); | 9 olsq cons c income kokusai pcpi; EXECUTION ******************************************************************************* Current sample: 1993 to 2003 *** WARNING in line 4 Procedure WRITE: Missing values for series ====> INCOME: 1, CONS: 1, KOKUSAI: 1 INCOME CONS CPI KOKUSAI 1993 . . 97.90000 . 1994 470862.40625 270932.09375 98.60000 4.39900 1995 480323.50000 276086.40625 98.50000 3.37300 1996 496822.18750 282897.09375 98.60000 3.10700 1997 505622.59375 284989.31250 100.40000 2.35500 1998 500329.09375 284352.59375 101.00000 1.57100 1999 499651.00000 284242.68750 100.70000 1.75900 2000 511569.09375 285750.09375 100.00000 1.73500 2001 512608.50000 288777.00000 99.30000 1.32200 2002 511056.00000 290356.40625 98.40000 1.23700 2003 517727.31250 291004.50000 98.10000 1.01300 Current sample: 1994 to 2003 Equation 1 ============ Method of estimation = Ordinary Least Squares Dependent variable: CONS Current sample: 1994 to 2003 Number of observations: 10 Mean of dep. var. = 283939. LM het. test = 1.06887 [.301] Std. dev. of dep. var. = 6245.76 Durbin-Watson = 2.30029 [.536,.827] Sum of squared residuals = .146641E+08 Jarque-Bera test = .548500 [.760] Variance of residuals = .183302E+07 Ramsey's RESET2 = .503765 [.501] Std. error of regression = 1353.89 F (zero slopes) = 183.534 [.000] R-squared = .958232 Schwarz B.I.C. = 87.4836 Adjusted R-squared = .953011 Log likelihood = -85.1810 Estimated Standard Variable Coefficient Error t-statistic P-value C 78760.7 15151.2 5.19832 [.001] INCOME .409818 .030250 13.5475 [.000] Equation 2 ============ Method of estimation = Ordinary Least Squares Dependent variable: CONS Current sample: 1994 to 2003 Number of observations: 10 Mean of dep. var. = 283939. LM het. test = .657584 [.417] Std. dev. of dep. var. = 6245.76 Durbin-Watson = 1.93411 [.141,.797] Sum of squared residuals = .110104E+08 Jarque-Bera test = .066485 [.967] Variance of residuals = .157292E+07 Ramsey's RESET2 = .196698 [.673] Std. error of regression = 1254.16 F (zero slopes) = 108.103 [.000] R-squared = .968639 Schwarz B.I.C. = 87.2021 Adjusted R-squared = .959679 Log likelihood = -83.7482 Estimated Standard Variable Coefficient Error t-statistic P-value C 134565. 39212.5 3.43170 [.011] INCOME .305034 .074242 4.10864 [.005] KOKUSAI -1529.01 1003.22 -1.52411 [.171] Equation 3 ============ Method of estimation = Ordinary Least Squares Dependent variable: CONS Current sample: 1994 to 2003 Number of observations: 10 Mean of dep. var. = 283939. LM het. test = .714646 [.398] Std. dev. of dep. var. = 6245.76 Durbin-Watson = 1.86744 [.024,.917] Sum of squared residuals = .108470E+08 Jarque-Bera test = .472872 [.789] Variance of residuals = .180783E+07 Ramsey's RESET2 = .269006 [.626] Std. error of regression = 1344.55 F (zero slopes) = 62.7344 [.000] R-squared = .969105 Schwarz B.I.C. = 88.2786 Adjusted R-squared = .953657 Log likelihood = -83.6734 Estimated Standard Variable Coefficient Error t-statistic P-value C 132379. 42662.6 3.10294 [.021] INCOME .308920 .080635 3.83108 [.009] KOKUSAI -1417.01 1138.20 -1.24496 [.260] PCPI -184.963 615.116 -.300697 [.774] ******************************************************************************* END OF OUTPUT. TOTAL NUMBER OF WARNING MESSAGES: 1 MEMORY USAGE: ITEM: DATA ARRAY TOTAL MEMORY UNITS: (4-BYTE WORDS) (MEGABYTES) MEMORY ALLOCATED : 500000 4.0 MEMORY ACTUALLY REQUIRED : 1018 2.1 CURRENT VARIABLE STORAGE : 650 =============================================================================== TSP (特に,「TSP through the Looking Glass」) の使い方 画面左下の「スタート」をクリック →「すべてのプログラム(P)」を選択(XPの場合?) → マウスを「TSP 4.5」の位置に →「TSP through the Looking Glass」をマウスの左ボタンをクリック → (1) Open File の画面で,過去に作ったTSPファイルを再編集したいのなら,そのファイルを選択 または (2) Open File の画面で,新規作成であれば,キャンセルをクリック → 画面上の左から2つ目のアイコン (マウスを乗せると New Input File と表示) をクリック → 画面の左側に TSP プログラムを編集 → 画面上の右から3つ目の「TSP」というアイコン (マウスを乗せると Run Project と表示) をクリック →「Would you like to save the file before sending it to TSP?」のメッセージで,「はい(Y)」を選択 → Save File As の画面が出たら,適当なファイル名(拡張子は .TSP)を付けるて,「保存(S)」を選択 → 結果が左側に表示される。 =============================================================================== 参考書 和合 肇, 伴 金美 『TSPによる経済データの分析』 第2版 出版社: 東京大学出版会 ISBN: 4130410679 (1995/02) 価格: ¥4,410 (税込) 縄田 和満 『TSPによる計量経済分析入門』 出版社: 朝倉書店 ISBN: 4254121199 (1997/05) 価格: ¥3,150 (税込)