Follow-up Comment #15, patch #6650 (project pspp):

Your two comments made me realize the need for two distinct functions to
accumulate the covariance matrix: one to be used for listwise deletion of
missing values, and another to be used for pairwise deletion. So I made those
two functions, and now covariance_accumulate just calls the appropriate one.
The question of pairwise or listwise deletion is the most important question
when computing the covariance matrix, so this is a big improvement.

I also altered the use of MV_ANY to be a value stored in the struct during
initialization. This made the list of arguments to covariance_matrix_init
longer.

About point number 2: As John said, update_moments does not depend on a test
that is invariant in the loops in which it is called, so I made the change he
suggested. But cat_value_update does depend on the loop: It checks to see if a
variable is categorical, and it's called inside a loop over the variables. I
don't see any way around this without making the code more cumbersome, for
example, by re-writing another, custom version of cat_value_update.

Latest patch attached.

(file #16766)
    _______________________________________________________

Additional Item Attachment:

File name: cov5.patch                     Size:18 KB


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/patch/?6650>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/



_______________________________________________
pspp-dev mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/pspp-dev

Reply via email to