diff options
author | Thomas White <taw@physics.org> | 2010-05-27 17:10:04 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2010-05-27 17:10:04 +0200 |
commit | 0a721b5c0b022208b567dae7e0638b9da9c27cbd (patch) | |
tree | e56273b8177b1dabe2a05ea5ecb49315d4206b3e /src/likelihood.c | |
parent | 7c45e455a6ee020174580355f746e7b03a1119df (diff) |
Handle I0 == 1.0 correctly
Diffstat (limited to 'src/likelihood.c')
-rw-r--r-- | src/likelihood.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/likelihood.c b/src/likelihood.c index dd10c562..95f005c7 100644 --- a/src/likelihood.c +++ b/src/likelihood.c @@ -26,13 +26,13 @@ void detwin_intensities(const double *model, double *new_pattern, void scale_intensities(const double *model, double *new_pattern, const unsigned int *model_counts, - unsigned int *new_counts, double f0) + unsigned int *new_counts, double f0, int f0_valid) { double s; unsigned int i; s = stat_scale_intensity(model, model_counts, new_pattern, new_counts); - if ( f0 != 1.0 ) printf("%f %f\n", s, f0); + if ( f0_valid ) printf("%f %f\n", s, f0); /* NaN -> abort */ if ( isnan(s) ) return; |