Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(12)  |  Call(10)  |  Derive(0)  |  Import(2)

src/p/e/PEATDB-2.3/PEATDB/Ekin/Base.py   PEATDB(Download)
import IO
from Convert import EkinConvert
from PEATDB.Ekin.Dataset import EkinDataset
from List_Utils import *
import Fitting
        self.length = len(self.datasets)
        #here we need to add to self.data
        for i in range(8):
        #print newdata
        if newdata == None:
            ek = EkinDataset(xy=xydata)
            #check for old or bad data
        if type(data) is types.DictType: #old format
            x,y,a,xerr,yerr = EkinConvert.ekin2xy(data, getall=1, geterrors=True)
            return EkinDataset(x=x,y=y,active=a,xerrs=xerr,yerrs=yerr)
        elif not type(data) is EkinDataset:
            return None
            #datasets[name] = EkinConvert.xy2ekin([xdata,row])
	    datasets[name] = EkinDataset(xy=[xdata,row])
        for d in datasets.keys():
            self.insertDataset(datasets[d], d)

src/p/e/PEATDB-2.3/PEATDB/Ekin/Fitting.py   PEATDB(Download)
       Note: errors are added +/- values'''
    from PEATDB.Ekin.Dataset import EkinDataset
    grad=1e-6; conv=1e-6
    for k in kwargs:
                mut_y.append(yd[i] + random.uniform(-yuncert,yuncert))
        ek = EkinDataset(xy=[mut_x,mut_y],active=a)
        fitres, X = doFit(ek, model=model, fitdata=fitdata, grad=1e-6, conv=1e-6,
                                silent=True, guess=guess, noiter=100)