aboutsummaryrefslogtreecommitdiff
path: root/src/statistics.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2010-08-26 16:58:21 +0200
committerThomas White <taw@physics.org>2012-02-22 15:26:56 +0100
commitd45677c6b6c671676c5487cb25fb01d7f7d02702 (patch)
treeef3e25aeab98eef210cce545362cfb4dc95c082e /src/statistics.c
parentb22e7b46c84bcb1f6d469baa274583f4c526e2f4 (diff)
compare_hkl: Get rid of Riso
Diffstat (limited to 'src/statistics.c')
-rw-r--r--src/statistics.c42
1 files changed, 1 insertions, 41 deletions
diff --git a/src/statistics.c b/src/statistics.c
index 27b5b8c5..81b84598 100644
--- a/src/statistics.c
+++ b/src/statistics.c
@@ -35,7 +35,6 @@ enum {
R_1,
R_2,
R_DIFF,
- R_ISO
};
@@ -198,33 +197,6 @@ static double internal_rdiff(const double *ref1, const double *ref2,
}
-static double internal_riso(const double *ref1, const double *ref2,
- ReflItemList *items, double scale)
-{
- double top = 0.0;
- double bot = 0.0;
- int i;
-
- for ( i=0; i<num_items(items); i++ ) {
-
- double i1, i2;
- struct refl_item *it;
- signed int h, k, l;
-
- it = get_item(items, i);
- h = it->h; k = it->k; l = it->l;
-
- i1 = lookup_intensity(ref1, h, k, l);
- i2 = lookup_intensity(ref2, h, k, l);
-
- top += fabs(i1 - i2);
- bot += fabs(i1 + i2);
-
- }
-
- return 2.0*top/bot;
-}
-
static double calc_r(double scale, void *params)
{
@@ -237,8 +209,6 @@ static double calc_r(double scale, void *params)
return internal_r2(rp->ref1, rp->ref2, rp->items, scale);
case R_DIFF :
return internal_rdiff(rp->ref1, rp->ref2, rp->items, scale);
- case R_ISO :
- return internal_riso(rp->ref1, rp->ref2, rp->items, scale);
}
ERROR("No such FoM!\n");
@@ -277,11 +247,8 @@ static double r_minimised(const double *ref1, const double *ref2,
case R_DIFF :
scale = stat_scale_sqrti(ref1, ref2, items);
break;
- case R_ISO :
- scale = stat_scale_intensity(ref1, ref2, items);
- break;
}
- STATUS("Initial scale factor estimate: %5.2e\n", scale);
+ //STATUS("Initial scale factor estimate: %5.2e\n", scale);
/* Probably within an order of magnitude either side */
gsl_min_fminimizer_set(s, &F, scale, scale/10.0, scale*10.0);
@@ -338,13 +305,6 @@ double stat_rdiff(const double *ref1, const double *ref2,
}
-double stat_riso(const double *ref1, const double *ref2,
- ReflItemList *items, double *scalep)
-{
- return r_minimised(ref1, ref2, items, scalep, R_ISO);
-}
-
-
double stat_pearson(const double *ref1, const double *ref2, ReflItemList *items)
{
double *vec1, *vec2;