0
$\begingroup$

This question is motivated by a ton of prior questions of the form: When can I use [insert statistical technique]? In "contract programming", one cannot call a function without satisfying its preconditions. Is there an analog to this in a library of statistical functions where the necessary preconditions for a function are automatically verified prior to making the call? Or where I am obliged to manually assert that these preconditions hold (so that I am, at least, reminded of what they are) before I can call a function?

And if not, why not?

$\endgroup$
  • 1
    $\begingroup$ You set a "wilcoxon-mann-whitney" flag to your post and a t-test flag. Apparently you are asking a very broad and unspecific question based on some concrete case. Maybe that specific case would suit this forum answering format better. As it stands, I personally do not want to be questioned about t-tests everytime I invoke one. $\endgroup$ – Bernhard Oct 29 '19 at 12:23
  • 1
    $\begingroup$ The premise of this question is that somehow statistics is a matter of applying functions to values. That is so far removed from any conventional understanding or description of statistics that I must ask for some elaboration: could you help us see how this premise applies, perhaps by providing an example of what you have in mind? $\endgroup$ – whuber Oct 29 '19 at 13:29
2
$\begingroup$

Some software will check for some conditions, e.g. the absence of perfect collinearity. But you cannot check for all conditions, because those conditions aren't usually that black or white. What you are estimating are models, and models are by definition simplifications of reality. A simplification is just another way of saying "wrong is some useful way". So we would expect some conditions of a model to be somewhat violated, we just don't want those violations to be too large. What "too large" just depends. Try implement that in software...

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.