ddad0ae7f8f2536cc7f50fab0e18ba634b5a6570
[pspp-builds.git] / src / command.def
1 /* PSPP - computes sample statistics.
2    Copyright (C) 1997-9, 2000 Free Software Foundation, Inc.
3    Written by Ben Pfaff <blp@gnu.org>.
4
5    This program is free software; you can redistribute it and/or
6    modify it under the terms of the GNU General Public License as
7    published by the Free Software Foundation; either version 2 of the
8    License, or (at your option) any later version.
9
10    This program is distributed in the hope that it will be useful, but
11    WITHOUT ANY WARRANTY; without even the implied warranty of
12    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13    General Public License for more details.
14
15    You should have received a copy of the GNU General Public License
16    along with this program; if not, write to the Free Software
17    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
18    02111-1307, USA. */
19
20 /* State abbreviations. */
21 #define INIT STATE_INIT
22 #define INPU STATE_INPUT
23 #define TRAN STATE_TRANS
24 #define PROC STATE_PROC
25 #define ERRO STATE_ERROR
26
27 UNIMPL ("ACF",                    ERRO, ERRO, ERRO, ERRO)
28 UNIMPL ("ADD FILES",              ERRO, ERRO, ERRO, ERRO)
29 DEFCMD ("ADD VALUE LABELS",       ERRO, INPU, TRAN, TRAN, cmd_add_value_labels)
30 DEFCMD ("AGGREGATE",              ERRO, ERRO, PROC, TRAN, cmd_aggregate)
31 UNIMPL ("ANOVA",                  ERRO, ERRO, ERRO, ERRO)
32 DEFCMD ("APPLY DICTIONARY",       ERRO, ERRO, TRAN, TRAN, cmd_apply_dictionary)
33 DEFCMD ("AUTORECODE",             ERRO, ERRO, PROC, PROC, cmd_autorecode)
34 SPCCMD ("BEGIN DATA",             ERRO, ERRO, PROC, PROC, cmd_begin_data)
35 DEFCMD ("BREAK",                  ERRO, INPU, TRAN, TRAN, cmd_break)
36 UNIMPL ("CASEPLOT",               ERRO, ERRO, ERRO, ERRO)
37 UNIMPL ("CASESTOVARS",            ERRO, ERRO, ERRO, ERRO)
38 UNIMPL ("CCF",                    ERRO, ERRO, ERRO, ERRO)
39 DEFCMD ("CLEAR TRANSFORMATIONS",  ERRO, INPU, TRAN, TRAN, cmd_clear_transformations)
40 UNIMPL ("CLUSTER",                ERRO, ERRO, ERRO, ERRO)
41 UNIMPL ("COMMENT",                ERRO, ERRO, ERRO, ERRO)
42 DEFCMD ("COMPUTE",                ERRO, INPU, TRAN, TRAN, cmd_compute)
43 UNIMPL ("CONJOINT",               ERRO, ERRO, ERRO, ERRO)
44 DEFCMD ("CORRELATIONS",           ERRO, ERRO, PROC, PROC, cmd_correlations)
45 DEFCMD ("COUNT",                  ERRO, INPU, TRAN, TRAN, cmd_count)
46 UNIMPL ("CREATE",                 ERRO, ERRO, ERRO, ERRO)
47 DEFCMD ("CROSSTABS",              ERRO, ERRO, PROC, PROC, cmd_crosstabs)
48 UNIMPL ("CURVEFIT",               ERRO, ERRO, ERRO, ERRO)
49 DEFCMD ("DATA LIST",              TRAN, INPU, TRAN, TRAN, cmd_data_list)
50 UNIMPL ("DATE",                   ERRO, ERRO, ERRO, ERRO)
51 DBGCMD ("DEBUG CASEFILE",         INIT, INPU, TRAN, PROC, cmd_debug_casefile)
52 DBGCMD ("DEBUG EVALUATE",         INIT, INPU, TRAN, PROC, cmd_debug_evaluate)
53 DBGCMD ("DEBUG MOMENTS",          INIT, INPU, TRAN, PROC, cmd_debug_moments)
54 DBGCMD ("DEBUG POOL",             INIT, INPU, TRAN, PROC, cmd_debug_pool)
55 DEFCMD ("DESCRIPTIVES",           ERRO, ERRO, PROC, PROC, cmd_descriptives)
56 UNIMPL ("DISCRIMINANT",           ERRO, ERRO, ERRO, ERRO)
57 DEFCMD ("DISPLAY",                ERRO, INPU, TRAN, PROC, cmd_display)
58 SPCCMD ("DOCUMENT",               ERRO, INPU, TRAN, TRAN, cmd_document)
59 DEFCMD ("DO IF",                  ERRO, INPU, TRAN, TRAN, cmd_do_if)
60 DEFCMD ("DO REPEAT",              ERRO, INPU, TRAN, TRAN, cmd_do_repeat)
61 DEFCMD ("DROP DOCUMENTS",         INIT, INPU, TRAN, PROC, cmd_drop_documents)
62 UNIMPL ("EDIT",                   ERRO, ERRO, ERRO, ERRO)
63 DEFCMD ("ELSE",                   ERRO, INPU, TRAN, TRAN, cmd_else)
64 DEFCMD ("ELSE IF",                ERRO, INPU, TRAN, TRAN, cmd_else_if)
65 DEFCMD ("END CASE",               ERRO, INPU, ERRO, ERRO, cmd_end_case)
66 DEFCMD ("END FILE",               ERRO, INPU, ERRO, ERRO, cmd_end_file)
67 DEFCMD ("END FILE TYPE",          ERRO, TRAN, ERRO, ERRO, cmd_end_file_type)
68 DEFCMD ("END IF",                 ERRO, INPU, TRAN, TRAN, cmd_end_if)
69 DEFCMD ("END INPUT PROGRAM",      ERRO, TRAN, ERRO, ERRO, cmd_end_input_program)
70 DEFCMD ("END LOOP",               ERRO, INPU, TRAN, TRAN, cmd_end_loop)
71 DEFCMD ("END REPEAT",             ERRO, INPU, TRAN, TRAN, cmd_end_repeat)
72 DEFCMD ("ERASE",                  INIT, INPU, TRAN, PROC, cmd_erase)
73 DEFCMD ("EXAMINE",                ERRO, ERRO, PROC, PROC, cmd_examine)
74 DEFCMD ("EXECUTE",                ERRO, ERRO, PROC, PROC, cmd_execute)
75 DEFCMD ("EXIT",                   INIT, INPU, TRAN, PROC, cmd_exit)
76 DEFCMD ("EXPORT",                 ERRO, ERRO, PROC, PROC, cmd_export)
77 UNIMPL ("FACTOR",                 ERRO, ERRO, ERRO, ERRO)
78 DEFCMD ("FILE HANDLE",            INIT, INPU, TRAN, PROC, cmd_file_handle)
79 SPCCMD ("FILE LABEL",             INIT, INPU, TRAN, PROC, cmd_file_label)
80 DEFCMD ("FILE TYPE",              INPU, ERRO, INPU, INPU, cmd_file_type)
81 DEFCMD ("FILTER",                 ERRO, ERRO, TRAN, TRAN, cmd_filter)
82 DEFCMD ("FINISH",                 INIT, INPU, TRAN, PROC, cmd_finish)
83 UNIMPL ("FIT",                    ERRO, ERRO, ERRO, ERRO)
84 DEFCMD ("FLIP",                   ERRO, ERRO, PROC, PROC, cmd_flip)
85 DEFCMD ("FORMATS",                INIT, INPU, TRAN, PROC, cmd_formats)
86 DEFCMD ("FREQUENCIES",            ERRO, ERRO, PROC, PROC, cmd_frequencies)
87 DEFCMD ("GET",                    TRAN, ERRO, TRAN, TRAN, cmd_get)
88 UNIMPL ("GET TRANSLATE",          ERRO, ERRO, ERRO, ERRO)
89 UNIMPL ("GLM",                    ERRO, ERRO, ERRO, ERRO)
90 UNIMPL ("GRAPH",                  ERRO, ERRO, ERRO, ERRO)
91 DEFCMD ("HOST",                   INIT, INPU, TRAN, PROC, cmd_host)
92 DEFCMD ("IF",                     ERRO, INPU, TRAN, TRAN, cmd_if)
93 UNIMPL ("IGRAPH",                 ERRO, ERRO, ERRO, ERRO)
94 DEFCMD ("IMPORT",                 TRAN, ERRO, TRAN, TRAN, cmd_import)
95 DEFCMD ("INCLUDE",                INIT, INPU, TRAN, PROC, cmd_include)
96 UNIMPL ("INFO",                   ERRO, ERRO, ERRO, ERRO)
97 UNIMPL ("INPUT MATRIX",           ERRO, ERRO, ERRO, ERRO)
98 DEFCMD ("INPUT PROGRAM",          INPU, ERRO, INPU, INPU, cmd_input_program)
99 UNIMPL ("KEYED DATA LIST",        ERRO, ERRO, ERRO, ERRO)
100 DEFCMD ("LEAVE",                  ERRO, INPU, TRAN, TRAN, cmd_leave)
101 DEFCMD ("LIST",                   ERRO, ERRO, PROC, PROC, cmd_list)
102 DEFCMD ("LOOP",                   ERRO, INPU, TRAN, TRAN, cmd_loop)
103 DEFCMD ("MATCH FILES",            TRAN, ERRO, TRAN, PROC, cmd_match_files)
104 DEFCMD ("MATRIX DATA",            TRAN, ERRO, TRAN, TRAN, cmd_matrix_data)
105 UNIMPL ("MCONVERT",               ERRO, ERRO, ERRO, ERRO)
106 DEFCMD ("MEANS",                  ERRO, ERRO, PROC, PROC, cmd_means)
107 DEFCMD ("MISSING VALUES",         ERRO, INPU, TRAN, TRAN, cmd_missing_values)
108 DEFCMD ("MODIFY VARS",            ERRO, ERRO, TRAN, PROC, cmd_modify_vars)
109 UNIMPL ("MULT RESPONSE",          ERRO, ERRO, ERRO, ERRO)
110 DEFCMD ("NEW FILE",               INIT, ERRO, INIT, INIT, cmd_new_file)
111 DEFCMD ("N",                      INIT, INPU, TRAN, TRAN, cmd_n_of_cases)
112 DEFCMD ("N OF CASES",             INIT, INPU, TRAN, TRAN, cmd_n_of_cases)
113 UNIMPL ("NONPAR CORR",            ERRO, ERRO, ERRO, ERRO)
114 UNIMPL ("NPAR TESTS",             ERRO, ERRO, ERRO, ERRO)
115 UNIMPL ("NUMBERED",               ERRO, ERRO, ERRO, ERRO)
116 DEFCMD ("NUMERIC",                ERRO, INPU, TRAN, TRAN, cmd_numeric)
117 DEFCMD ("ONEWAY",                 ERRO, ERRO, PROC, PROC, cmd_oneway)
118 UNIMPL ("PACF",                   ERRO, ERRO, ERRO, ERRO)
119 UNIMPL ("PARTIAL CORR",           ERRO, ERRO, ERRO, ERRO)
120 DEFCMD ("PEARSON CORRELATIONS",   ERRO, ERRO, PROC, PROC, cmd_correlations)
121 DEFCMD ("PERMISSIONS",            INIT, INPU, TRAN, PROC, cmd_permissions)
122 UNIMPL ("PLOT",                   ERRO, ERRO, ERRO, ERRO)
123 UNIMPL ("POINT",                  ERRO, ERRO, ERRO, ERRO)
124 UNIMPL ("PPLOT",                  ERRO, ERRO, ERRO, ERRO)
125 UNIMPL ("PREDICT",                ERRO, ERRO, ERRO, ERRO)
126 UNIMPL ("PRESERVE",               ERRO, ERRO, ERRO, ERRO)
127 DEFCMD ("PRINT EJECT",            ERRO, INPU, TRAN, TRAN, cmd_print_eject)
128 DEFCMD ("PRINT",                  ERRO, INPU, TRAN, TRAN, cmd_print)
129 DEFCMD ("PRINT FORMATS",          ERRO, INPU, TRAN, TRAN, cmd_print_formats)
130 DEFCMD ("PRINT SPACE",            ERRO, INPU, TRAN, TRAN, cmd_print_space)
131 UNIMPL ("PROCEDURE OUTPUT",       ERRO, ERRO, ERRO, ERRO)
132 DEFCMD ("PROCESS IF",             ERRO, ERRO, TRAN, TRAN, cmd_process_if)
133 UNIMPL ("PROXIMITIES",            ERRO, ERRO, ERRO, ERRO)
134 DEFCMD ("Q",                      INIT, INPU, TRAN, PROC, cmd_exit)
135 UNIMPL ("QUICK CLUSTER",          ERRO, ERRO, ERRO, ERRO)
136 DEFCMD ("QUIT",                   INIT, INPU, TRAN, PROC, cmd_exit)
137 UNIMPL ("RANK",                   ERRO, ERRO, ERRO, ERRO)
138 DEFCMD ("RECODE",                 ERRO, INPU, TRAN, TRAN, cmd_recode)
139 DEFCMD ("RECORD TYPE",            ERRO, INPU, ERRO, ERRO, cmd_record_type)
140 UNIMPL ("REFORMAT",               ERRO, ERRO, ERRO, ERRO)
141 UNIMPL ("REGRESSION",             ERRO, ERRO, ERRO, ERRO)
142 DEFCMD ("RENAME VARIABLES",       ERRO, INPU, TRAN, PROC, cmd_rename_variables)
143 DEFCMD ("REPEATING DATA",         ERRO, INPU, ERRO, ERRO, cmd_repeating_data)
144 UNIMPL ("REPORT",                 ERRO, ERRO, ERRO, ERRO)
145 DEFCMD ("REREAD",                 ERRO, INPU, ERRO, ERRO, cmd_reread)
146 UNIMPL ("RESTORE",                ERRO, ERRO, ERRO, ERRO)
147 UNIMPL ("RMV",                    ERRO, ERRO, ERRO, ERRO)
148 DEFCMD ("SAMPLE",                 ERRO, ERRO, TRAN, TRAN, cmd_sample)
149 DEFCMD ("SAVE",                   ERRO, ERRO, PROC, PROC, cmd_save)
150 UNIMPL ("SAVE TRANSLATE",         ERRO, ERRO, ERRO, ERRO)
151 UNIMPL ("SCRIPT",                 ERRO, ERRO, ERRO, ERRO)
152 DEFCMD ("SELECT IF",              ERRO, ERRO, TRAN, TRAN, cmd_select_if)
153 DEFCMD ("SET",                    INIT, INPU, TRAN, PROC, cmd_set)
154 DEFCMD ("SHOW",                   INIT, INPU, TRAN, PROC, cmd_show)
155 DEFCMD ("SORT CASES",             ERRO, ERRO, PROC, PROC, cmd_sort_cases)
156 DEFCMD ("SORT",                   ERRO, ERRO, PROC, PROC, cmd_sort_cases)
157 UNIMPL ("SPCHART",                ERRO, ERRO, ERRO, ERRO)
158 DEFCMD ("SPLIT FILE",             ERRO, INPU, TRAN, TRAN, cmd_split_file)
159 DEFCMD ("STRING",                 ERRO, INPU, TRAN, TRAN, cmd_string)
160 SPCCMD ("SUBTITLE",               INIT, INPU, TRAN, PROC, cmd_subtitle)
161 UNIMPL ("SUMMARIZE",              ERRO, ERRO, ERRO, ERRO)
162 UNIMPL ("SURVIVAL",               ERRO, ERRO, ERRO, ERRO)
163 DEFCMD ("SYSFILE INFO",           INIT, INPU, TRAN, PROC, cmd_sysfile_info)
164 DEFCMD ("TEMPORARY",              ERRO, ERRO, TRAN, TRAN, cmd_temporary)
165 SPCCMD ("TITLE",                  INIT, INPU, TRAN, PROC, cmd_title)
166 UNIMPL ("TSET",                   ERRO, ERRO, ERRO, ERRO)
167 UNIMPL ("TSHOW",                  ERRO, ERRO, ERRO, ERRO)
168 UNIMPL ("TSPLOT",                 ERRO, ERRO, ERRO, ERRO)
169 DEFCMD ("T-TEST",                 ERRO, ERRO, PROC, PROC, cmd_t_test)
170 UNIMPL ("UNIANOVA",               ERRO, ERRO, ERRO, ERRO)
171 UNIMPL ("UNNUMBERED",             ERRO, ERRO, ERRO, ERRO)
172 UNIMPL ("UPDATE",                 ERRO, ERRO, ERRO, ERRO)
173 DEFCMD ("USE",                    ERRO, ERRO, TRAN, TRAN, cmd_use)
174 DEFCMD ("VALUE LABELS",           ERRO, INPU, TRAN, TRAN, cmd_value_labels)
175 DEFCMD ("VARIABLE LABELS",        ERRO, INPU, TRAN, TRAN, cmd_variable_labels)
176 UNIMPL ("VARIABLE LEVEL",         ERRO, ERRO, ERRO, ERRO)
177 UNIMPL ("VARSTOCASES",            ERRO, ERRO, ERRO, ERRO)
178 DEFCMD ("VECTOR",                 ERRO, INPU, TRAN, TRAN, cmd_vector)
179 UNIMPL ("VERIFY",                 ERRO, ERRO, ERRO, ERRO)
180 DEFCMD ("WEIGHT",                 ERRO, INPU, TRAN, TRAN, cmd_weight)
181 DEFCMD ("WRITE",                  ERRO, INPU, TRAN, TRAN, cmd_write)
182 DEFCMD ("WRITE FORMATS",          ERRO, INPU, TRAN, TRAN, cmd_write_formats)
183 DEFCMD ("XSAVE",                  ERRO, INPU, TRAN, TRAN, cmd_xsave)