Changeset 2e07e8f in sasview


Ignore:
Timestamp:
May 7, 2008 5:58:36 PM (17 years ago)
Author:
Gervaise Alina <gervyh@…>
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:
abad620
Parents:
383189f9
Message:

litle change on fit

Location:
guitools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • guitools/fitDialog.py

    r5e14aee r2e07e8f  
    289289                    tempy.append(y_model) 
    290290                #Set the fit parameter display when  FitDialog is opened again 
    291                 self.Avalue=cstA 
    292                 self.Bvalue=cstB 
     291                self.Avalue=cstB 
     292                self.Bvalue=cstA 
    293293                self.ErrAvalue=errA 
    294294                self.ErrBvalue=errB 
     
    297297                 
    298298                # Display the fitting value on the Fit Dialog 
    299                 self._onsetValues(cstA, cstB, errA,errB,chisqr) 
     299                self._onsetValues(cstB, cstA, errA,errB,chisqr) 
    300300                
    301301                
  • guitools/transform.py

    r2e014bf r2e07e8f  
    116116        
    117117        return math.fabs(err) 
     118def errToLog10X(x,y=None,dx=None,dy=None): 
     119    """ 
     120        calculate error of Log(x) 
     121        @param x: float value 
     122        @param dx: float value 
     123    """ 
     124    if dx==None: 
     125        dx = 0 
     126    if x!=0: 
     127        dx = dx/(x*math.log(10)) 
     128    else: 
     129        raise ValueError, "errToLogX: divide by zero" 
     130     
     131    if math.fabs(dx) >= math.fabs(x): 
     132        dx = 0.9*x 
     133     
     134    return dx 
    118135     
    119136def errToLogX(x,y=None,dx=None,dy=None): 
Note: See TracChangeset for help on using the changeset viewer.