-
-
Save even4void/7416545 to your computer and use it in GitHub Desktop.
Computing some probability value from Student distribution
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Time-stamp: <2013-11-11 17:58:52 chl> | |
// gcc -Wall 1.c -lgsl -lgslcblas -lm | |
#include <stdio.h> | |
#include <gsl/gsl_cdf.h> | |
int main(void) { | |
double p; | |
double x = 2.0; | |
int nu = 6; | |
p = gsl_cdf_tdist_P(x, nu); | |
printf ("prob(x < %5.2f) = %10.8f\n", x, p); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment