From be66ac26aaa48186e127091011be175dd20c17d8 Mon Sep 17 00:00:00 2001 From: John Darrington Date: Sat, 4 Mar 2006 02:24:40 +0000 Subject: [PATCH] removed obsolete files --- lib/Makefile.am | 5 - lib/linreg/Makefile.am | 15 -- lib/linreg/coefficient.c | 133 --------------- lib/linreg/linreg.c | 353 --------------------------------------- lib/linreg/pspp_linreg.h | 206 ----------------------- src/Make.build | 19 --- src/Makefile.am | 285 ------------------------------- src/command.def | 193 --------------------- src/format.def | 65 ------- 9 files changed, 1274 deletions(-) delete mode 100644 lib/Makefile.am delete mode 100644 lib/linreg/Makefile.am delete mode 100644 lib/linreg/coefficient.c delete mode 100644 lib/linreg/linreg.c delete mode 100644 lib/linreg/pspp_linreg.h delete mode 100644 src/Make.build delete mode 100644 src/Makefile.am delete mode 100644 src/command.def delete mode 100644 src/format.def diff --git a/lib/Makefile.am b/lib/Makefile.am deleted file mode 100644 index 99cc4b8e..00000000 --- a/lib/Makefile.am +++ /dev/null @@ -1,5 +0,0 @@ -## Process this file with automake to produce Makefile.in -*- makefile -*- - -SUBDIRS = gsl-extras linreg - -MAINTAINERCLEANFILES = Makefile.in diff --git a/lib/linreg/Makefile.am b/lib/linreg/Makefile.am deleted file mode 100644 index 998b75ef..00000000 --- a/lib/linreg/Makefile.am +++ /dev/null @@ -1,15 +0,0 @@ -## Process this file with automake to produce Makefile.in -*- makefile -*- - -noinst_LIBRARIES = liblinreg.a - -AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/src - -AM_CFLAGS= - -if cc_is_gcc -AM_CFLAGS+=-Wall -W -Wwrite-strings -Wstrict-prototypes \ --Wpointer-arith -Wno-sign-compare -Wmissing-prototypes \ --ansi -endif - -liblinreg_a_SOURCES = coefficient.c sweep.c linreg.c pspp_linreg.h diff --git a/lib/linreg/coefficient.c b/lib/linreg/coefficient.c deleted file mode 100644 index 5b9266e2..00000000 --- a/lib/linreg/coefficient.c +++ /dev/null @@ -1,133 +0,0 @@ -/* lib/linreg/coefficient.c - - Copyright (C) 2005 Free Software Foundation, Inc. - Written by Jason H Stover. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or (at - your option) any later version. - - This program is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02111-1307, USA. - */ - -/* - Accessor functions for matching coefficients and variables. - */ -#include -#include "pspp_linreg.h" -#include - - -struct varinfo -{ - const struct variable *v; /* Variable associated with this - coefficient. Note this variable may not - be unique. In other words, a - coefficient structure may have other - v_info's, each with its own variable. - */ - const union value *val; /* Value of the variable v which this - varinfo refers to. This member is relevant - only to categorical variables. - */ -}; - -void pspp_linreg_coeff_free (struct pspp_linreg_coeff *c) -{ - free (c); -} - -/* - Initialize the variable and value pointers inside the - coefficient structures for the linear model. - */ -void -pspp_linreg_coeff_init (pspp_linreg_cache *c, struct design_matrix *X) -{ - size_t i; - size_t j; - int n_vals = 1; - struct pspp_linreg_coeff *coeff; - - c->coeff = xnmalloc (X->m->size2 + 1, sizeof (*c->coeff)); - for (i = 0; i < X->m->size2; i++) - { - j = i + 1; /* The first coefficient is the intercept. */ - coeff = c->coeff + j; - coeff->n_vars = n_vals; /* Currently, no procedures allow interactions. - This will have to change when procedures that - allow interaction terms are written. - */ - coeff->v_info = xnmalloc (coeff->n_vars, sizeof (*coeff->v_info)); - assert (coeff->v_info != NULL); - coeff->v_info->v = (const struct variable *) design_matrix_col_to_var (X, i); - - if (coeff->v_info->v->type == ALPHA) - { - size_t k; - k = design_matrix_var_to_column (X, coeff->v_info->v); - assert (k <= i); - k = i - k; - coeff->v_info->val = cat_subscript_to_value (k, (struct variable *) coeff->v_info->v); - } - } -} -void -pspp_linreg_coeff_set_estimate (struct pspp_linreg_coeff *c, - double estimate) -{ - c->estimate = estimate; -} -void -pspp_linreg_coeff_set_std_err (struct pspp_linreg_coeff *c, - double std_err) -{ - c->std_err = std_err; -} -/* - How many variables are associated with this coefficient? - */ -int -pspp_linreg_coeff_get_n_vars (struct pspp_linreg_coeff *c) -{ - return c->n_vars; -} -/* - Which variable does this coefficient match? - */ -const struct variable * -pspp_linreg_coeff_get_var (struct pspp_linreg_coeff *c, int i) -{ - assert (i < c->n_vars); - return (c->v_info + i)->v; -} -/* - Which value is associated with this coefficient/variable comination? -*/ -const union value * -pspp_linreg_coeff_get_value (struct pspp_linreg_coeff *c, - const struct variable *v) -{ - int i = 0; - const struct variable *candidate; - - while (i < c->n_vars) - { - candidate = pspp_linreg_coeff_get_var (c, i); - if (v->index == candidate->index) - { - return (c->v_info + i)->val; - } - i++; - } - return NULL; -} diff --git a/lib/linreg/linreg.c b/lib/linreg/linreg.c deleted file mode 100644 index 17833e57..00000000 --- a/lib/linreg/linreg.c +++ /dev/null @@ -1,353 +0,0 @@ -/* lib/linreg/linreg.c - - Copyright (C) 2005 Free Software Foundation, Inc. - Written by Jason H. Stover. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or (at - your option) any later version. - - This program is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02111-1307, USA. -*/ - -/* - Find the least-squares estimate of b for the linear model: - - Y = Xb + Z - - where Y is an n-by-1 column vector, X is an n-by-p matrix of - independent variables, b is a p-by-1 vector of regression coefficients, - and Z is an n-by-1 normally-distributed random vector with independent - identically distributed components with mean 0. - - This estimate is found via the sweep operator or singular-value - decomposition with gsl. - - - References: - - 1. Matrix Computations, third edition. GH Golub and CF Van Loan. - The Johns Hopkins University Press. 1996. ISBN 0-8018-5414-8. - - 2. Numerical Analysis for Statisticians. K Lange. Springer. 1999. - ISBN 0-387-94979-8. - - 3. Numerical Linear Algebra for Applications in Statistics. JE Gentle. - Springer. 1998. ISBN 0-387-98542-5. -*/ - -#include "pspp_linreg.h" -#include -/* - Get the mean and standard deviation of a vector - of doubles via a form of the Kalman filter as - described on page 32 of [3]. - */ -static int -linreg_mean_std (gsl_vector_const_view v, double *mp, double *sp, double *ssp) -{ - size_t i; - double j = 0.0; - double d; - double tmp; - double mean; - double variance; - - mean = gsl_vector_get (&v.vector, 0); - variance = 0; - for (i = 1; i < v.vector.size; i++) - { - j = (double) i + 1.0; - tmp = gsl_vector_get (&v.vector, i); - d = (tmp - mean) / j; - mean += d; - variance += j * (j - 1.0) * d * d; - } - *mp = mean; - *sp = sqrt (variance / (j - 1.0)); - *ssp = variance; - - return GSL_SUCCESS; -} - -/* - Allocate a pspp_linreg_cache and return a pointer - to it. n is the number of cases, p is the number of - independent variables. - */ -pspp_linreg_cache * -pspp_linreg_cache_alloc (size_t n, size_t p) -{ - pspp_linreg_cache *c; - - c = (pspp_linreg_cache *) malloc (sizeof (pspp_linreg_cache)); - c->indep_means = gsl_vector_alloc (p); - c->indep_std = gsl_vector_alloc (p); - c->ssx = gsl_vector_alloc (p); /* Sums of squares for the independent - variables. - */ - c->ss_indeps = gsl_vector_alloc (p); /* Sums of squares for the model - parameters. - */ - c->cov = gsl_matrix_alloc (p + 1, p + 1); /* Covariance matrix. */ - c->n_obs = n; - c->n_indeps = p; - /* - Default settings. - */ - c->method = PSPP_LINREG_SWEEP; - - return c; -} - -void -pspp_linreg_cache_free (pspp_linreg_cache * c) -{ - int i; - - gsl_vector_free (c->indep_means); - gsl_vector_free (c->indep_std); - gsl_vector_free (c->ss_indeps); - gsl_matrix_free (c->cov); - pspp_linreg_coeff_free (c->coeff); - free (c); -} - -/* - Fit the linear model via least squares. All pointers passed to pspp_linreg - are assumed to be allocated to the correct size and initialized to the - values as indicated by opts. - */ -int -pspp_linreg (const gsl_vector * Y, const gsl_matrix * X, - const pspp_linreg_opts * opts, pspp_linreg_cache * cache) -{ - int rc; - gsl_matrix *design; - gsl_matrix_view xtx; - gsl_matrix_view xm; - gsl_matrix_view xmxtx; - gsl_vector_view xty; - gsl_vector_view xi; - gsl_vector_view xj; - gsl_vector *param_estimates; - - size_t i; - size_t j; - double tmp; - double m; - double s; - double ss; - - if (cache == NULL) - { - return GSL_EFAULT; - } - if (opts->get_depvar_mean_std) - { - linreg_mean_std (gsl_vector_const_subvector (Y, 0, Y->size), - &m, &s, &ss); - cache->depvar_mean = m; - cache->depvar_std = s; - cache->sst = ss; - } - for (i = 0; i < cache->n_indeps; i++) - { - if (opts->get_indep_mean_std[i]) - { - linreg_mean_std (gsl_matrix_const_column (X, i), &m, &s, &ss); - gsl_vector_set (cache->indep_means, i, m); - gsl_vector_set (cache->indep_std, i, s); - gsl_vector_set (cache->ssx, i, ss); - } - } - cache->dft = cache->n_obs - 1; - cache->dfm = cache->n_indeps; - cache->dfe = cache->dft - cache->dfm; - cache->n_coeffs = X->size2 + 1; /* Adjust this later to allow for regression - through the origin. - */ - if (cache->method == PSPP_LINREG_SWEEP) - { - gsl_matrix *sw; - /* - Subtract the means to improve the condition of the design - matrix. This requires copying X and Y. We do not divide by the - standard deviations of the independent variables here since doing - so would cause a miscalculation of the residual sums of - squares. Dividing by the standard deviation is done GSL's linear - regression functions, so if the design matrix has a poor - condition, use QR decomposition. - - The design matrix here does not include a column for the intercept - (i.e., a column of 1's). If using PSPP_LINREG_QR, we need that column, - so design is allocated here when sweeping, or below if using QR. - */ - design = gsl_matrix_alloc (X->size1, X->size2); - for (i = 0; i < X->size2; i++) - { - m = gsl_vector_get (cache->indep_means, i); - for (j = 0; j < X->size1; j++) - { - tmp = (gsl_matrix_get (X, j, i) - m); - gsl_matrix_set (design, j, i, tmp); - } - } - sw = gsl_matrix_calloc (cache->n_indeps + 1, cache->n_indeps + 1); - xtx = gsl_matrix_submatrix (sw, 0, 0, cache->n_indeps, cache->n_indeps); - - for (i = 0; i < xtx.matrix.size1; i++) - { - tmp = gsl_vector_get (cache->ssx, i); - gsl_matrix_set (&(xtx.matrix), i, i, tmp); - xi = gsl_matrix_column (design, i); - for (j = (i + 1); j < xtx.matrix.size2; j++) - { - xj = gsl_matrix_column (design, j); - gsl_blas_ddot (&(xi.vector), &(xj.vector), &tmp); - gsl_matrix_set (&(xtx.matrix), i, j, tmp); - } - } - - gsl_matrix_set (sw, cache->n_indeps, cache->n_indeps, cache->sst); - xty = gsl_matrix_column (sw, cache->n_indeps); - /* - This loop starts at 1, with i=0 outside the loop, so we can get - the model sum of squares due to the first independent variable. - */ - xi = gsl_matrix_column (design, 0); - gsl_blas_ddot (&(xi.vector), Y, &tmp); - gsl_vector_set (&(xty.vector), 0, tmp); - tmp *= tmp / gsl_vector_get (cache->ssx, 0); - gsl_vector_set (cache->ss_indeps, 0, tmp); - for (i = 1; i < cache->n_indeps; i++) - { - xi = gsl_matrix_column (design, i); - gsl_blas_ddot (&(xi.vector), Y, &tmp); - gsl_vector_set (&(xty.vector), i, tmp); - } - - /* - Sweep on the matrix sw, which contains XtX, XtY and YtY. - */ - pspp_reg_sweep (sw); - cache->sse = gsl_matrix_get (sw, cache->n_indeps, cache->n_indeps); - cache->mse = cache->sse / cache->dfe; - /* - Get the intercept. - */ - m = cache->depvar_mean; - for (i = 0; i < cache->n_indeps; i++) - { - tmp = gsl_matrix_get (sw, i, cache->n_indeps); - cache->coeff[i + 1].estimate = tmp; - m -= tmp * gsl_vector_get (cache->indep_means, i); - } - /* - Get the covariance matrix of the parameter estimates. - Only the upper triangle is necessary. - */ - - /* - The loops below do not compute the entries related - to the estimated intercept. - */ - for (i = 0; i < cache->n_indeps; i++) - for (j = i; j < cache->n_indeps; j++) - { - tmp = -1.0 * cache->mse * gsl_matrix_get (sw, i, j); - gsl_matrix_set (cache->cov, i + 1, j + 1, tmp); - } - /* - Get the covariances related to the intercept. - */ - xtx = gsl_matrix_submatrix (sw, 0, 0, cache->n_indeps, cache->n_indeps); - xmxtx = gsl_matrix_submatrix (cache->cov, 0, 1, 1, cache->n_indeps); - xm = gsl_matrix_view_vector (cache->indep_means, 1, cache->n_indeps); - rc = gsl_blas_dsymm (CblasRight, CblasUpper, cache->mse, - &xtx.matrix, &xm.matrix, 0.0, &xmxtx.matrix); - if (rc == GSL_SUCCESS) - { - tmp = cache->mse / cache->n_obs; - for (i = 1; i < 1 + cache->n_indeps; i++) - { - tmp -= gsl_matrix_get (cache->cov, 0, i) - * gsl_vector_get (cache->indep_means, i - 1); - } - gsl_matrix_set (cache->cov, 0, 0, tmp); - - cache->coeff[0].estimate = m; - } - else - { - fprintf (stderr, "%s:%d:gsl_blas_dsymm: %s\n", - __FILE__, __LINE__, gsl_strerror (rc)); - exit (rc); - } - gsl_matrix_free (sw); - } - else - { - /* - Use QR decomposition via GSL. - */ - - param_estimates = gsl_vector_alloc (1 + X->size2); - design = gsl_matrix_alloc (X->size1, 1 + X->size2); - - for (j = 0; j < X->size1; j++) - { - gsl_matrix_set (design, j, 0, 1.0); - for (i = 0; i < X->size2; i++) - { - tmp = gsl_matrix_get (X, j, i); - gsl_matrix_set (design, j, i + 1, tmp); - } - } - gsl_multifit_linear_workspace *wk = - gsl_multifit_linear_alloc (design->size1, design->size2); - rc = gsl_multifit_linear (design, Y, param_estimates, - cache->cov, &(cache->sse), wk); - for (i = 0; i < cache->n_coeffs; i++) - { - cache->coeff[i].estimate = gsl_vector_get (param_estimates, i); - } - if (rc == GSL_SUCCESS) - { - gsl_multifit_linear_free (wk); - gsl_vector_free (param_estimates); - } - else - { - fprintf (stderr, "%s:%d: gsl_multifit_linear returned %d\n", - __FILE__, __LINE__, rc); - } - } - - - cache->ssm = cache->sst - cache->sse; - /* - Get the remaining sums of squares for the independent - variables. - */ - m = 0; - for (i = 1; i < cache->n_indeps; i++) - { - j = i - 1; - m += gsl_vector_get (cache->ss_indeps, j); - tmp = cache->ssm - m; - gsl_vector_set (cache->ss_indeps, i, tmp); - } - - gsl_matrix_free (design); - return GSL_SUCCESS; -} diff --git a/lib/linreg/pspp_linreg.h b/lib/linreg/pspp_linreg.h deleted file mode 100644 index a83f7b3d..00000000 --- a/lib/linreg/pspp_linreg.h +++ /dev/null @@ -1,206 +0,0 @@ -/* lib/linreg/pspp_linreg.h - - Copyright (C) 2005 Free Software Foundation, Inc. - Written by Jason H Stover. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or (at - your option) any later version. - - This program is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02111-1307, USA. - */ - -/* - Find the least-squares estimate of b for the linear model: - - Y = Xb + Z - - where Y is an n-by-1 column vector, X is an n-by-p matrix of - independent variables, b is a p-by-1 vector of regression coefficients, - and Z is an n-by-1 normally-distributed random vector with independent - identically distributed components with mean 0. - - This estimate is found via the sweep operator or singular-value - decomposition. - - - References: - - Matrix Computations, third edition. GH Golub and CF Van Loan. - The Johns Hopkins University Press. 1996. ISBN 0-8018-5414-8. - - Numerical Analysis for Statisticians. K Lange. Springer. 1999. - ISBN 0-387-94979-8. - - Numerical Linear Algebra for Applications in Statistics. JE Gentle. - Springer. 1998. ISBN 0-387-98542-5. - */ -#ifndef PSPP_LINREG_H -#define PSPP_LINREG_H 1 -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#define PSPP_LINREG_VAL_NOT_FOUND -1 -enum -{ - PSPP_LINREG_SWEEP, - PSPP_LINREG_SVD -}; - -/* - Cache for the relevant data from the model. There are several - members which the caller might not use, and which could use a lot of - storage. Therefore non-essential members of the struct will be - allocated only when requested. - */ -struct pspp_linreg_coeff -{ - double estimate; /* Estimated coefficient. */ - double std_err; /* Standard error of the estimate. */ - struct varinfo *v_info; /* Information pertaining to the - variable(s) associated with this - coefficient. The calling function - should initialize this value with the - functions in coefficient.c. The - estimation procedure ignores this - member. It is here so the caller can - match parameters with relevant variables - and values. If the coefficient is - associated with an interaction, then - v_info contains information for multiple - variables. - */ - int n_vars; /* Number of variables associated with this coefficient. - Coefficients corresponding to interaction terms will - have more than one variable. - */ -}; -struct pspp_linreg_cache_struct -{ - int n_obs; /* Number of observations. */ - int n_indeps; /* Number of independent variables. */ - int n_coeffs; - - /* - The variable struct is ignored during estimation. - It is here so the calling procedure can - find the variable used in the model. - */ - const struct variable *depvar; - - gsl_vector *residuals; - struct pspp_linreg_coeff *coeff; - int method; /* Method to use to estimate parameters. */ - /* - Means and standard deviations of the variables. - If these pointers are null when pspp_linreg() is - called, pspp_linreg() will compute their values. - - Entry i of indep_means is the mean of independent - variable i, whose observations are stored in the ith - column of the design matrix. - */ - double depvar_mean; - double depvar_std; - gsl_vector *indep_means; - gsl_vector *indep_std; - - /* - Sums of squares. - */ - double ssm; /* Sums of squares for the overall model. */ - gsl_vector *ss_indeps; /* Sums of squares from each - independent variable. - */ - double sst; /* Sum of squares total. */ - double sse; /* Sum of squares error. */ - double mse; /* Mean squared error. This is just sse / dfe, but - since it is the best unbiased estimate of the population - variance, it has its own entry here. - */ - gsl_vector *ssx; /* Centered sums of squares for independent variables, - i.e. \sum (x[i] - mean(x))^2. - */ - double ssy; /* Centered sums of squares for dependent variable. */ - /* - Covariance matrix of the parameter estimates. - */ - gsl_matrix *cov; - /* - Degrees of freedom. - */ - double dft; - double dfe; - double dfm; - - /* - 'Hat' or Hessian matrix, i.e. (X'X)^{-1}, where X is our - design matrix. - */ - gsl_matrix *hat; -}; -typedef struct pspp_linreg_cache_struct pspp_linreg_cache; - -/* - Options describing what special values should be computed. - */ -struct pspp_linreg_opts_struct -{ - int resid; /* Should the residuals be returned? */ - - int get_depvar_mean_std; - int *get_indep_mean_std; /* Array of booleans dictating which - independent variables need their means - and standard deviations computed within - pspp_linreg. This array MUST be of - length n_indeps. If element i is 1, - pspp_linreg will compute the mean and - variance of indpendent variable i. If - element i is 0, it will not compute the - mean and standard deviation, and assume - the values are stored. - cache->indep_mean[i] is the mean and - cache->indep_std[i] is the sample - standard deviation. - */ -}; -typedef struct pspp_linreg_opts_struct pspp_linreg_opts; - -int pspp_reg_sweep (gsl_matrix * A); - -pspp_linreg_cache *pspp_linreg_cache_alloc (size_t n, size_t p); - -void pspp_linreg_cache_free (pspp_linreg_cache * cache); - -int pspp_linreg (const gsl_vector * Y, const gsl_matrix * X, - const pspp_linreg_opts * opts, pspp_linreg_cache * cache); -void pspp_linreg_coeff_init (pspp_linreg_cache *, struct design_matrix *); - -void pspp_linreg_coeff_free (struct pspp_linreg_coeff *); - -void pspp_linreg_coeff_set_estimate (struct pspp_linreg_coeff *, double); - -void pspp_linreg_coeff_set_std_err (struct pspp_linreg_coeff *, double); - -int pspp_linreg_coeff_get_n_vars (struct pspp_linreg_coeff *); - -const struct variable *pspp_linreg_coeff_get_var (struct pspp_linreg_coeff *, int); - -const union value *pspp_linreg_coeff_get_value (struct pspp_linreg_coeff *, const struct variable *); -#endif diff --git a/src/Make.build b/src/Make.build deleted file mode 100644 index 6a4f3656..00000000 --- a/src/Make.build +++ /dev/null @@ -1,19 +0,0 @@ -## Makefile.am include file -*- makefile -*- - -AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/src -I$(top_srcdir)/lib \ --I$(top_srcdir)/intl -I$(top_srcdir)/gl -I$(top_builddir)/gl - -AM_CFLAGS= - -if cc_is_gcc -AM_CFLAGS+=-Wall -W -Wwrite-strings -Wstrict-prototypes \ --Wpointer-arith -Wno-sign-compare -Wmissing-prototypes -endif - -if unix -AM_CFLAGS+=-Dunix -endif - -if msdos -AM_CFLAGS+=-D__MSDOS__ -endif diff --git a/src/Makefile.am b/src/Makefile.am deleted file mode 100644 index 3d616d31..00000000 --- a/src/Makefile.am +++ /dev/null @@ -1,285 +0,0 @@ -## Process this file with automake to produce Makefile.in -*- makefile -*- - -# PSPP - -include $(top_srcdir)/src/Make.build - -SUBDIRS = expressions - -# If you change this, you must also change the corresponding line in -# config/Makefile.am -pkgsysconfdir = $(sysconfdir)/@PACKAGE@ - -bin_PROGRAMS = pspp - -MAINTAINERCLEANFILES = Makefile.in -EXTRA_DIST = $(q_sources_q) q2c.c -ETAGS_ARGS = -l c $(q_sources_c) -SUFFIXES = .q - -$(q_sources_c): q2c$(EXEEXT) -.q.c: - ./q2c $< $@ - -q_sources_c = \ - correlations.c \ - crosstabs.c \ - examine.c \ - file-handle.c \ - frequencies.c \ - list.c \ - means.c \ - oneway.c \ - rank.c \ - regression.c \ - set.c \ - t-test.c - -CLEANFILES=$(q_sources_c) -DISTCLEANFILES=version.c - -q_sources_q = \ - correlations.q \ - crosstabs.q \ - examine.q \ - file-handle.q \ - frequencies.q \ - list.q \ - means.q \ - oneway.q \ - rank.q \ - regression.q \ - set.q \ - t-test.q - -if WITHCHARTS -chart_sources = \ - barchart.c \ - box-whisker.c \ - cartesian.c \ - plot-chart.c \ - plot-hist.c \ - piechart.c -else -chart_sources = dummy-chart.c -endif - -pspp_SOURCES = \ - $(q_sources_c) \ - $(chart_sources) \ - aggregate.c \ - algorithm.c \ - algorithm.h \ - alloc.c \ - alloc.h \ - any-reader.c \ - any-reader.h \ - any-writer.c \ - any-writer.h \ - apply-dict.c \ - ascii.c \ - autorecode.c \ - bitvector.h \ - calendar.c \ - calendar.h \ - case.c \ - case.h \ - casefile.c \ - casefile.h \ - casefile-test.c \ - cat.c \ - cat.h \ - cat-routines.h \ - chart.c \ - chart.h \ - ctl-stack.c \ - ctl-stack.h \ - cmdline.c \ - cmdline.h \ - command.c \ - command.def \ - command.h \ - compute.c \ - copyleft.c \ - copyleft.h \ - count.c \ - data-in.c \ - data-in.h \ - data-list.c \ - data-list.h \ - data-out.c \ - date.c \ - debug-print.h \ - descript.c \ - design-matrix.h \ - design-matrix.c \ - dfm-read.c \ - dfm-read.h \ - dfm-write.c \ - dfm-write.h \ - dictionary.c \ - dictionary.h \ - do-if.c \ - echo.c \ - error.c \ - error.h \ - factor_stats.c \ - factor_stats.h \ - file-handle-def.c \ - file-handle-def.h \ - file-handle.h \ - file-type.c \ - filename.c \ - filename.h \ - flip.c \ - font.h \ - format.c \ - format-prs.c \ - format.def \ - format.h \ - formats.c \ - get.c \ - getl.c \ - getl.h \ - glob.c \ - glob.h \ - groff-font.c \ - group.c \ - group.h \ - group_proc.h \ - hash.c \ - hash.h \ - histogram.c \ - histogram.h \ - html.c \ - htmlP.h \ - include.c \ - inpt-pgm.c \ - lexer.c \ - lexer.h \ - lex-def.h \ - lex-def.c \ - levene.c \ - levene.h \ - linked-list.c \ - linked-list.h \ - loop.c \ - magic.c \ - magic.h \ - main.c \ - main.h \ - matrix-data.c \ - mis-val.c \ - misc.c \ - misc.h \ - missing-values.c \ - missing-values.h \ - modify-vars.c \ - moments.c \ - moments.h \ - numeric.c \ - output.c \ - output.h \ - percentiles.c \ - percentiles.h \ - permissions.c \ - pfm-read.c \ - pfm-read.h \ - pfm-write.c \ - pfm-write.h \ - pool.c \ - pool.h \ - postscript.c \ - print.c \ - random.c \ - random.h \ - range-prs.c \ - range-prs.h \ - readln.c \ - readln.h \ - recode.c \ - rename-vars.c \ - regression_export.h \ - repeat.c \ - repeat.h \ - sample.c \ - sel-if.c \ - settings.c \ - settings.h \ - sfm-read.c \ - sfm-read.h \ - sfm-write.c \ - sfm-write.h \ - sfmP.h \ - som.c \ - som.h \ - sort.c \ - sort.h \ - sort-prs.c \ - sort-prs.h \ - split-file.c \ - str.c \ - str.h \ - subclist.c \ - subclist.h \ - sysfile-info.c \ - tab.c \ - tab.h \ - temporary.c \ - scratch-handle.c \ - scratch-handle.h \ - scratch-reader.c \ - scratch-reader.h \ - scratch-writer.c \ - scratch-writer.h \ - mkfile.c \ - mkfile.h \ - title.c \ - val.h \ - val-labs.c \ - value-labels.c \ - value-labels.h \ - var-display.c \ - var-labs.c \ - var.h \ - vars-atr.c \ - vars-prs.c \ - vector.c \ - version.h \ - vfm.c \ - vfm.h \ - vfmP.h \ - weight.c - -pspp_LDADD = \ - expressions/libexpressions.a \ - ../lib/gsl-extras/libgsl-extras.a \ - ../lib/linreg/liblinreg.a \ - ../gl/libgl.a \ - @LIBINTL@ - -nodist_pspp_SOURCES = version.c - -version.c: - echo "#include " > version.c - echo "#include \"version.h\"" > version.c - echo "const char bare_version[] = \"@VERSION@\";" >> version.c - echo "const char version[] = \"GNU @PACKAGE@ @VERSION@\";" >> version.c - echo "const char stat_version[] = \"GNU @PACKAGE@ @VERSION@ \ -(`date`).\";" >> version.c - echo "const char host_system[] = \"$(host_triplet)\";" >> version.c - echo "const char build_system[] = \"$(build_triplet)\";" >> version.c - echo "const char default_config_path[] =\ -\"~/.pspp:$(pkgsysconfdir)\";" >> version.c - echo "const char include_path[] =\ -\"./:~/.pspp/include:$(pkgdatadir)\";" >> version.c - echo "const char groff_font_path[] = \"~/.pspp/font:\" \\" >> version.c - echo " \"$(pkgdatadir)/font:\" \\" >> version.c - echo " \"/usr/local/lib/groff/font:\" \\" >> version.c - echo " \"/usr/lib/groff/font:\" \\" >> version.c - echo " \"/usr/local/share/groff/font:\" \\" >> version.c - echo " \"/usr/share/groff/font\";" >> version.c - echo "const char locale_dir[] = \"$(datadir)/locale\";" >> version.c - -noinst_PROGRAMS = q2c -q2c_SOURCES = q2c.c diff --git a/src/command.def b/src/command.def deleted file mode 100644 index 737b7eed..00000000 --- a/src/command.def +++ /dev/null @@ -1,193 +0,0 @@ -/* PSPP - computes sample statistics. - Copyright (C) 1997-9, 2000 Free Software Foundation, Inc. - Written by Ben Pfaff . - - This program is free software; you can redistribute it and/or - modify it under the terms of the GNU General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - This program is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02110-1301, USA. */ - -/* State abbreviations. */ -#define INIT STATE_INIT -#define INPU STATE_INPUT -#define TRAN STATE_TRANS -#define PROC STATE_PROC -#define ERRO STATE_ERROR - -UNIMPL ("ACF", ERRO, ERRO, ERRO, ERRO, "Autocorrelation function") -UNIMPL ("ADD FILES", ERRO, ERRO, ERRO, ERRO, "Add files to dictionary") -DEFCMD ("ADD VALUE LABELS", ERRO, INPU, TRAN, TRAN, cmd_add_value_labels) -DEFCMD ("AGGREGATE", ERRO, ERRO, PROC, TRAN, cmd_aggregate) -UNIMPL ("ALSCAL", ERRO, ERRO, ERRO, ERRO, "Multidimensional scaling") -UNIMPL ("ANOVA", ERRO, ERRO, ERRO, ERRO, "Factorial analysis of variance") -DEFCMD ("APPLY DICTIONARY", ERRO, ERRO, TRAN, TRAN, cmd_apply_dictionary) -DEFCMD ("AUTORECODE", ERRO, ERRO, PROC, PROC, cmd_autorecode) -SPCCMD ("BEGIN DATA", ERRO, ERRO, PROC, PROC, cmd_begin_data) -DEFCMD ("BREAK", ERRO, INPU, TRAN, TRAN, cmd_break) -UNIMPL ("CASEPLOT", ERRO, ERRO, ERRO, ERRO, "Plot time series") -UNIMPL ("CASESTOVARS", ERRO, ERRO, ERRO, ERRO, "Restructure complex data") -UNIMPL ("CCF", ERRO, ERRO, ERRO, ERRO, "Time series cross correlation") -DEFCMD ("CLEAR TRANSFORMATIONS", ERRO, INPU, TRAN, TRAN, cmd_clear_transformations) -DEFCMD ("CLOSE FILE HANDLE", INIT, INPU, TRAN, PROC, cmd_close_file_handle) -UNIMPL ("CLUSTER", ERRO, ERRO, ERRO, ERRO, "Hierachial clustering") -DEFCMD ("COMPUTE", ERRO, INPU, TRAN, TRAN, cmd_compute) -UNIMPL ("CONJOINT", ERRO, ERRO, ERRO, ERRO, "Analyse full concept data") -DEFCMD ("CORRELATIONS", ERRO, ERRO, PROC, PROC, cmd_correlations) -DEFCMD ("COUNT", ERRO, INPU, TRAN, TRAN, cmd_count) -UNIMPL ("COXREG", ERRO, ERRO, ERRO, ERRO, "Cox proportional hazards regression") -UNIMPL ("CREATE", ERRO, ERRO, ERRO, ERRO, "Create time series data") -DEFCMD ("CROSSTABS", ERRO, ERRO, PROC, PROC, cmd_crosstabs) -UNIMPL ("CURVEFIT", ERRO, ERRO, ERRO, ERRO, "Fit curve to line plot") -DEFCMD ("DATA LIST", TRAN, INPU, TRAN, TRAN, cmd_data_list) -UNIMPL ("DATE", ERRO, ERRO, ERRO, ERRO, "Create time series data") -DBGCMD ("DEBUG CASEFILE", INIT, INPU, TRAN, PROC, cmd_debug_casefile) -DBGCMD ("DEBUG EVALUATE", INIT, INPU, TRAN, PROC, cmd_debug_evaluate) -DBGCMD ("DEBUG MOMENTS", INIT, INPU, TRAN, PROC, cmd_debug_moments) -DBGCMD ("DEBUG POOL", INIT, INPU, TRAN, PROC, cmd_debug_pool) -DEFCMD ("DESCRIPTIVES", ERRO, ERRO, PROC, PROC, cmd_descriptives) -UNIMPL ("DISCRIMINANT", ERRO, ERRO, ERRO, ERRO, "Linear discriminant analysis") -DEFCMD ("DISPLAY", ERRO, INPU, TRAN, PROC, cmd_display) -SPCCMD ("DOCUMENT", ERRO, INPU, TRAN, TRAN, cmd_document) -DEFCMD ("DO IF", ERRO, INPU, TRAN, TRAN, cmd_do_if) -DEFCMD ("DO REPEAT", ERRO, INPU, TRAN, TRAN, cmd_do_repeat) -DEFCMD ("DROP DOCUMENTS", INIT, INPU, TRAN, PROC, cmd_drop_documents) -DEFCMD ("ECHO", INIT, INPU, TRAN, PROC, cmd_echo) -UNIMPL ("EDIT", ERRO, ERRO, ERRO, ERRO, "obsolete") -DEFCMD ("ELSE", ERRO, INPU, TRAN, TRAN, cmd_else) -DEFCMD ("ELSE IF", ERRO, INPU, TRAN, TRAN, cmd_else_if) -DEFCMD ("END CASE", ERRO, INPU, ERRO, ERRO, cmd_end_case) -DEFCMD ("END FILE", ERRO, INPU, ERRO, ERRO, cmd_end_file) -UNIMPL ("END FILE TYPE", ERRO, TRAN, ERRO, ERRO, "Ends complex data input") -DEFCMD ("END IF", ERRO, INPU, TRAN, TRAN, cmd_end_if) -DEFCMD ("END INPUT PROGRAM", ERRO, TRAN, ERRO, ERRO, cmd_end_input_program) -DEFCMD ("END LOOP", ERRO, INPU, TRAN, TRAN, cmd_end_loop) -DEFCMD ("END REPEAT", ERRO, INPU, TRAN, TRAN, cmd_end_repeat) -DEFCMD ("ERASE", INIT, INPU, TRAN, PROC, cmd_erase) -DEFCMD ("EXAMINE", ERRO, ERRO, PROC, PROC, cmd_examine) -DEFCMD ("EXECUTE", ERRO, ERRO, PROC, PROC, cmd_execute) -DEFCMD ("EXIT", INIT, INPU, TRAN, PROC, cmd_exit) -DEFCMD ("EXPORT", ERRO, ERRO, PROC, PROC, cmd_export) -UNIMPL ("FACTOR", ERRO, ERRO, ERRO, ERRO, "Factor analysis") -DEFCMD ("FILE HANDLE", INIT, INPU, TRAN, PROC, cmd_file_handle) -SPCCMD ("FILE LABEL", INIT, INPU, TRAN, PROC, cmd_file_label) -UNIMPL ("FILE TYPE", INPU, ERRO, INPU, INPU, "Complex data input") -DEFCMD ("FILTER", ERRO, ERRO, TRAN, TRAN, cmd_filter) -DEFCMD ("FINISH", INIT, INPU, TRAN, PROC, cmd_finish) -UNIMPL ("FIT", ERRO, ERRO, ERRO, ERRO, "Goodness of Fit") -DEFCMD ("FLIP", ERRO, ERRO, PROC, PROC, cmd_flip) -DEFCMD ("FORMATS", INIT, INPU, TRAN, PROC, cmd_formats) -DEFCMD ("FREQUENCIES", ERRO, ERRO, PROC, PROC, cmd_frequencies) -DEFCMD ("GET", TRAN, ERRO, TRAN, TRAN, cmd_get) -UNIMPL ("GET TRANSLATE", ERRO, ERRO, ERRO, ERRO, "Read other file formats") -UNIMPL ("GLM", ERRO, ERRO, ERRO, ERRO, "General Linear Model") -UNIMPL ("GRAPH", ERRO, ERRO, ERRO, ERRO, "Draw graphs") -DEFCMD ("HOST", INIT, INPU, TRAN, PROC, cmd_host) -DEFCMD ("IF", ERRO, INPU, TRAN, TRAN, cmd_if) -UNIMPL ("IGRAPH", ERRO, ERRO, ERRO, ERRO, "Interactive graphs") -DEFCMD ("IMPORT", TRAN, ERRO, TRAN, TRAN, cmd_import) -DEFCMD ("INCLUDE", INIT, INPU, TRAN, PROC, cmd_include) -UNIMPL ("INFO", ERRO, ERRO, ERRO, ERRO, "Local Documentation") -DEFCMD ("INPUT PROGRAM", INPU, ERRO, INPU, INPU, cmd_input_program) -UNIMPL ("KEYED DATA LIST", ERRO, ERRO, ERRO, ERRO, "Read nonsequential data") -UNIMPL ("KM", ERRO, ERRO, ERRO, ERRO, "Kaplan-Meier") -DEFCMD ("LEAVE", ERRO, INPU, TRAN, TRAN, cmd_leave) -DEFCMD ("LIST", ERRO, ERRO, PROC, PROC, cmd_list) -UNIMPL ("LOGISTIC REGRESSION", ERRO, ERRO, ERRO, ERRO, "Regression Analysis") -DEFCMD ("LOOP", ERRO, INPU, TRAN, TRAN, cmd_loop) -DEFCMD ("MATCH FILES", TRAN, ERRO, TRAN, PROC, cmd_match_files) -DEFCMD ("MATRIX DATA", TRAN, ERRO, TRAN, TRAN, cmd_matrix_data) -UNIMPL ("MCONVERT", ERRO, ERRO, ERRO, ERRO, "Convert covariance/correlation matrices") -DEFCMD ("MEANS", ERRO, ERRO, PROC, PROC, cmd_means) -DEFCMD ("MISSING VALUES", ERRO, INPU, TRAN, TRAN, cmd_missing_values) -DEFCMD ("MODIFY VARS", ERRO, ERRO, TRAN, PROC, cmd_modify_vars) -UNIMPL ("MULT RESPONSE", ERRO, ERRO, ERRO, ERRO, "Multiple reponse analysis") -UNIMPL ("MVA", ERRO, ERRO, ERRO, ERRO, "Missing value analysis") -DEFCMD ("NEW FILE", INIT, ERRO, INIT, INIT, cmd_new_file) -DEFCMD ("N", INIT, INPU, TRAN, TRAN, cmd_n_of_cases) -DEFCMD ("N OF CASES", INIT, INPU, TRAN, TRAN, cmd_n_of_cases) -UNIMPL ("NLR", ERRO, ERRO, ERRO, ERRO, "Non Linear Regression") -UNIMPL ("NONPAR CORR", ERRO, ERRO, ERRO, ERRO, "Nonparametric correlation") -UNIMPL ("NPAR TESTS", ERRO, ERRO, ERRO, ERRO, "Nonparametric tests") -UNIMPL ("NUMBERED", ERRO, ERRO, ERRO, ERRO, "") -DEFCMD ("NUMERIC", ERRO, INPU, TRAN, TRAN, cmd_numeric) -DEFCMD ("ONEWAY", ERRO, ERRO, PROC, PROC, cmd_oneway) -UNIMPL ("PACF", ERRO, ERRO, ERRO, ERRO, "Partial autocorrelation") -UNIMPL ("PARTIAL CORR", ERRO, ERRO, ERRO, ERRO, "Partial correlation") -DEFCMD ("PEARSON CORRELATIONS", ERRO, ERRO, PROC, PROC, cmd_correlations) -DEFCMD ("PERMISSIONS", INIT, INPU, TRAN, PROC, cmd_permissions) -UNIMPL ("POINT", ERRO, ERRO, ERRO, ERRO, "Marker in keyed file") -UNIMPL ("PPLOT", ERRO, ERRO, ERRO, ERRO, "Plot time series variables") -UNIMPL ("PREDICT", ERRO, ERRO, ERRO, ERRO, "Specify forecast period") -UNIMPL ("PRESERVE", ERRO, ERRO, ERRO, ERRO, "Push settings") -DEFCMD ("PRINT EJECT", ERRO, INPU, TRAN, TRAN, cmd_print_eject) -DEFCMD ("PRINT", ERRO, INPU, TRAN, TRAN, cmd_print) -DEFCMD ("PRINT FORMATS", ERRO, INPU, TRAN, TRAN, cmd_print_formats) -DEFCMD ("PRINT SPACE", ERRO, INPU, TRAN, TRAN, cmd_print_space) -UNIMPL ("PROCEDURE OUTPUT", ERRO, ERRO, ERRO, ERRO, "Specify output file") -UNIMPL ("PROBIT", ERRO, ERRO, ERRO, ERRO, "Probit analysis") -DEFCMD ("PROCESS IF", ERRO, ERRO, TRAN, TRAN, cmd_process_if) -UNIMPL ("PROXIMITIES", ERRO, ERRO, ERRO, ERRO, "Pairwise similarity") -DEFCMD ("Q", INIT, INPU, TRAN, PROC, cmd_exit) -UNIMPL ("QUICK CLUSTER", ERRO, ERRO, ERRO, ERRO, "Fast clustering") -DEFCMD ("QUIT", INIT, INPU, TRAN, PROC, cmd_exit) -UNIMPL ("RANK", ERRO, ERRO, ERRO, ERRO, "Create rank scores") -DEFCMD ("RECODE", ERRO, INPU, TRAN, TRAN, cmd_recode) -DEFCMD ("RECORD TYPE", ERRO, INPU, ERRO, ERRO, cmd_record_type) -UNIMPL ("REFORMAT", ERRO, ERRO, ERRO, ERRO, "Read obsolete files") -DEFCMD ("REGRESSION", ERRO, ERRO, PROC, PROC, cmd_regression) -DEFCMD ("RENAME VARIABLES", ERRO, INPU, TRAN, PROC, cmd_rename_variables) -UNIMPL ("REPEATING DATA", ERRO, INPU, ERRO, ERRO, "Specify multiple cases per input record") -UNIMPL ("REPORT", ERRO, ERRO, ERRO, ERRO, "Pretty print working file") -DEFCMD ("REREAD", ERRO, INPU, ERRO, ERRO, cmd_reread) -UNIMPL ("RESTORE", ERRO, ERRO, ERRO, ERRO, "Restore settings") -UNIMPL ("ROC", ERRO, ERRO, ERRO, ERRO, "Receiver operating characteristic") -UNIMPL ("RMV", ERRO, ERRO, ERRO, ERRO, "Replace missing values") -DEFCMD ("SAMPLE", ERRO, ERRO, TRAN, TRAN, cmd_sample) -DEFCMD ("SAVE", ERRO, ERRO, PROC, PROC, cmd_save) -UNIMPL ("SAVE TRANSLATE", ERRO, ERRO, ERRO, ERRO, "Save to foriegn format") -UNIMPL ("SCRIPT", ERRO, ERRO, ERRO, ERRO, "Run script file") -DEFCMD ("SELECT IF", ERRO, ERRO, TRAN, TRAN, cmd_select_if) -DEFCMD ("SET", INIT, INPU, TRAN, PROC, cmd_set) -DEFCMD ("SHOW", INIT, INPU, TRAN, PROC, cmd_show) -DEFCMD ("SORT CASES", ERRO, ERRO, PROC, PROC, cmd_sort_cases) -DEFCMD ("SORT", ERRO, ERRO, PROC, PROC, cmd_sort_cases) -UNIMPL ("SPCHART", ERRO, ERRO, ERRO, ERRO, "Plot control charts") -DEFCMD ("SPLIT FILE", ERRO, INPU, TRAN, TRAN, cmd_split_file) -DEFCMD ("STRING", ERRO, INPU, TRAN, TRAN, cmd_string) -SPCCMD ("SUBTITLE", INIT, INPU, TRAN, PROC, cmd_subtitle) -UNIMPL ("SUMMARIZE", ERRO, ERRO, ERRO, ERRO, "Univariate statistics") -UNIMPL ("SURVIVAL", ERRO, ERRO, ERRO, ERRO, "Survival analysis") -DEFCMD ("SYSFILE INFO", INIT, INPU, TRAN, PROC, cmd_sysfile_info) -DEFCMD ("TEMPORARY", ERRO, ERRO, TRAN, TRAN, cmd_temporary) -SPCCMD ("TITLE", INIT, INPU, TRAN, PROC, cmd_title) -UNIMPL ("TSET", ERRO, ERRO, ERRO, ERRO, "Set time sequence variables") -UNIMPL ("TSHOW", ERRO, ERRO, ERRO, ERRO, "Show time sequence variables") -UNIMPL ("TSPLOT", ERRO, ERRO, ERRO, ERRO, "Plot time sequence variables") -DEFCMD ("T-TEST", ERRO, ERRO, PROC, PROC, cmd_t_test) -UNIMPL ("UNIANOVA", ERRO, ERRO, ERRO, ERRO, "Univariate analysis") -UNIMPL ("UNNUMBERED", ERRO, ERRO, ERRO, ERRO, "obsolete") -UNIMPL ("UPDATE", ERRO, ERRO, ERRO, ERRO, "Update working file") -DEFCMD ("USE", ERRO, ERRO, TRAN, TRAN, cmd_use) -DEFCMD ("VALUE LABELS", ERRO, INPU, TRAN, TRAN, cmd_value_labels) -DEFCMD ("VARIABLE LABELS", ERRO, INPU, TRAN, TRAN, cmd_variable_labels) -DEFCMD ("VARIABLE ALIGNMENT", ERRO, INPU, TRAN, TRAN, cmd_variable_alignment) -DEFCMD ("VARIABLE LEVEL", ERRO, INPU, TRAN, TRAN, cmd_variable_level) -DEFCMD ("VARIABLE WIDTH", ERRO, INPU, TRAN, TRAN, cmd_variable_width) -UNIMPL ("VARSTOCASES", ERRO, ERRO, ERRO, ERRO, "Restructure complex data") -DEFCMD ("VECTOR", ERRO, INPU, TRAN, TRAN, cmd_vector) -UNIMPL ("VERIFY", ERRO, ERRO, ERRO, ERRO, "Report time series") -DEFCMD ("WEIGHT", ERRO, INPU, TRAN, TRAN, cmd_weight) -DEFCMD ("WRITE", ERRO, INPU, TRAN, TRAN, cmd_write) -DEFCMD ("WRITE FORMATS", ERRO, INPU, TRAN, TRAN, cmd_write_formats) -DEFCMD ("XEXPORT", ERRO, INPU, TRAN, TRAN, cmd_xexport) -DEFCMD ("XSAVE", ERRO, INPU, TRAN, TRAN, cmd_xsave) diff --git a/src/format.def b/src/format.def deleted file mode 100644 index 0dfc21c0..00000000 --- a/src/format.def +++ /dev/null @@ -1,65 +0,0 @@ -/* PSPP - computes sample statistics. - Copyright (C) 1997-9, 2000 Free Software Foundation, Inc. - Written by Ben Pfaff . - - This program is free software; you can redistribute it and/or - modify it under the terms of the GNU General Public License as - published by the Free Software Foundation; either version 2 of the - License, or (at your option) any later version. - - This program is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02110-1301, USA. */ - -/* Numeric and string formats. */ -DEFFMT (FMT_F, "F", 2, 1, 40, 1, 40, 0001, FMT_F, 5) -DEFFMT (FMT_N, "N", 2, 1, 40, 1, 40, 0011, FMT_F, 16) -DEFFMT (FMT_E, "E", 2, 1, 40, 6, 40, 0001, FMT_E, 17) -DEFFMT (FMT_COMMA, "COMMA", 2, 1, 40, 1, 40, 0001, FMT_COMMA, 3) -DEFFMT (FMT_DOT, "DOT", 2, 1, 40, 1, 40, 0001, FMT_DOT, 32) -DEFFMT (FMT_DOLLAR, "DOLLAR", 2, 1, 40, 2, 40, 0001, FMT_DOLLAR, 4) -DEFFMT (FMT_PCT, "PCT", 2, 1, 40, 2, 40, 0001, FMT_PCT, 31) -DEFFMT (FMT_Z, "Z", 2, 1, 40, 1, 40, 0011, FMT_F, 15) -DEFFMT (FMT_A, "A", 1, 1, 255, 1, 255, 0004, FMT_A, 1) -DEFFMT (FMT_AHEX, "AHEX", 1, 2, 510, 2, 510, 0006, FMT_A, 2) -DEFFMT (FMT_IB, "IB", 2, 1, 8, 1, 8, 0010, FMT_F, 6) -DEFFMT (FMT_P, "P", 2, 1, 16, 1, 16, 0011, FMT_F, 8) -DEFFMT (FMT_PIB, "PIB", 2, 1, 8, 1, 8, 0010, FMT_F, 9) -DEFFMT (FMT_PIBHEX, "PIBHEX", 2, 2, 16, 2, 16, 0002, FMT_F, 7) -DEFFMT (FMT_PK, "PK", 2, 1, 16, 1, 16, 0010, FMT_F, 10) -DEFFMT (FMT_RB, "RB", 1, 2, 8, 2, 8, 0002, FMT_F, 11) -DEFFMT (FMT_RBHEX, "RBHEX", 1, 4, 16, 4, 16, 0002, FMT_F, 12) - -/* Custom currency. */ -DEFFMT (FMT_CCA, "CCA", 2, -1, -1, 1, 40, 0020, FMT_CCA, 33) -DEFFMT (FMT_CCB, "CCB", 2, -1, -1, 1, 40, 0020, FMT_CCB, 34) -DEFFMT (FMT_CCC, "CCC", 2, -1, -1, 1, 40, 0020, FMT_CCC, 35) -DEFFMT (FMT_CCD, "CCD", 2, -1, -1, 1, 40, 0020, FMT_CCD, 36) -DEFFMT (FMT_CCE, "CCE", 2, -1, -1, 1, 40, 0020, FMT_CCE, 37) - -/* Date/time formats. */ -DEFFMT (FMT_DATE, "DATE", 1, 9, 40, 9, 40, 0001, FMT_DATE, 20) -DEFFMT (FMT_EDATE, "EDATE", 1, 8, 40, 8, 40, 0001, FMT_EDATE, 38) -DEFFMT (FMT_SDATE, "SDATE", 1, 8, 40, 8, 40, 0001, FMT_SDATE, 39) -DEFFMT (FMT_ADATE, "ADATE", 1, 8, 40, 8, 40, 0001, FMT_ADATE, 23) -DEFFMT (FMT_JDATE, "JDATE", 1, 5, 40, 5, 40, 0001, FMT_JDATE, 24) -DEFFMT (FMT_QYR, "QYR", 1, 4, 40, 6, 40, 0001, FMT_QYR, 29) -DEFFMT (FMT_MOYR, "MOYR", 1, 6, 40, 6, 40, 0001, FMT_MOYR, 28) -DEFFMT (FMT_WKYR, "WKYR", 1, 6, 40, 8, 40, 0001, FMT_WKYR, 30) -DEFFMT (FMT_DATETIME, "DATETIME", 2, 17, 40, 17, 40, 0001, FMT_DATETIME, 22) -DEFFMT (FMT_TIME, "TIME", 2, 5, 40, 5, 40, 0001, FMT_TIME, 21) -DEFFMT (FMT_DTIME, "DTIME", 2, 11, 40, 8, 40, 0001, FMT_DTIME, 25) -DEFFMT (FMT_WKDAY, "WKDAY", 1, 2, 40, 2, 40, 0001, FMT_WKDAY, 26) -DEFFMT (FMT_MONTH, "MONTH", 1, 3, 40, 3, 40, 0001, FMT_MONTH, 27) - -/* These aren't real formats. They're used by DATA LIST. */ -DEFFMT (FMT_T, "T", 1, 1,99999, 1,99999, 0000, FMT_T, -1) -DEFFMT (FMT_X, "X", 1, 1,99999, 1,99999, 0000, FMT_X, -1) -DEFFMT (FMT_DESCEND, "***", 1, 1,99999, 1,99999, 0000, -1, -1) -DEFFMT (FMT_NEWREC, "***", 1, 1,99999, 1,99999, 0000, -1, -1) -- 2.30.2