X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fchart.h;h=f2c9e501471151cc7282864f05bda72748070e4f;hb=5156fa5a8323a16f6b4bbc8950221cdc1d0e023d;hp=d22c394fdb21a0a21864fcaa26c5c24b5ec5d079;hpb=5501903810bcbae487b12bc44d9cbedf29644d96;p=pspp-builds.git diff --git a/src/chart.h b/src/chart.h index d22c394f..f2c9e501 100644 --- a/src/chart.h +++ b/src/chart.h @@ -77,6 +77,7 @@ int chart_initialise(struct chart *ch); void chart_finalise(struct chart *ch); +double chart_rounded_tick(double tick); void chart_write_xlabel(struct chart *ch, const char *label); void chart_write_ylabel(struct chart *ch, const char *label); @@ -118,10 +119,19 @@ struct normal_curve void histogram_write_legend(struct chart *ch, const struct normal_curve *norm); +/* Plot a gsl_histogram */ void histogram_plot(const gsl_histogram *hist, const char *factorname, const struct normal_curve *norm, short show_normal); +/* Create a gsl_histogram and set it's parameters based upon + x_min, x_max and bins. + The caller is responsible for freeing the histogram. +*/ +gsl_histogram * histogram_create(double bins, double x_min, double x_max) ; + + + struct slice { @@ -158,6 +168,7 @@ void chart_datum(struct chart *ch, int dataset, double x, double y); + enum CHART_DIM { CHART_DIM_X,