Changeset f193585 in sasview for guitools/transform.py
- Timestamp:
- Apr 28, 2008 5:48:59 PM (16 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 6ed101a
- Parents:
- 9e8dc22
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
guitools/transform.py
r46693050 rf193585 43 43 else: 44 44 raise ValueError,"cannot divide by zero" 45 def toOneOverSqrtX( x=None,y=None):45 def toOneOverSqrtX(y , x=None): 46 46 if y!=None: 47 47 if y > 0: … … 49 49 else: 50 50 raise ValueError,"cannot be computed" 51 if x!= None: 52 if x > 0: 53 return 1/math.sqrt(x) 54 else: 55 raise ValueError,"cannot be computed" 56 57 def toLogYX2(x,y): 51 52 53 def toLogYX2(y,x): 58 54 if y*(x**2) >0: 59 55 return math.log(y*(x**2)) … … 62 58 63 59 64 def toLogYX4( x, y):60 def toLogYX4(y, x): 65 61 if math.pow(x,4)*y > 0: 66 62 return math.log(math.pow(x,4)*y) 67 63 68 def toLogXY( x,y):64 def toLogXY(y,x): 69 65 """ 70 66 This function is used to load value on Plottable.View … … 85 81 @param dx: float value 86 82 """ 83 if dx==None: 84 dx=0 87 85 return dx 88 86
Note: See TracChangeset
for help on using the changeset viewer.