From: W. Trevor King Date: Thu, 12 Jul 2012 22:25:53 +0000 (-0400) Subject: Add explanatory message to analyze_surface_position_data's final==start error. X-Git-Tag: 0.7~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=e56cff18ed60dc8867d85f5690aca41c4b1b5546;p=pypiezo.git Add explanatory message to analyze_surface_position_data's final==start error. --- diff --git a/pypiezo/surface.py b/pypiezo/surface.py index a0f9055..fe096bb 100644 --- a/pypiezo/surface.py +++ b/pypiezo/surface.py @@ -177,7 +177,7 @@ def analyze_surface_position_data( start_pos = data['z'].min() final_pos = data['z'].max() if final_pos == start_pos: - raise SurfaceError() + raise SurfaceError('cannot fit a single approach step (too close?)') start_def = data['deflection'].min() final_def = data['deflection'].max() # start_def and start_pos are probably for 2 different points