Beispiel #1
0
def splitStd(x):
    ## extract numbers from strings like this: "-16.4pA±7.28pA"
    if x is None or x == '-' or '?' in x:
        return None, None
    if u'±' in x:
        x1, x2 = x.split(u'±')
        return pg.siEval(x1), pg.siEval(x2)
    else:
        return pg.siEval(x.lstrip('~')), None
Beispiel #2
0
def splitStd(x):
    ## extract numbers from strings like this: "-16.4pA±7.28pA"
    if x is None or x == '-' or '?' in x:
        return None, None
    if u'±' in x:
        x1, x2 = x.split(u'±')
        return pg.siEval(x1), pg.siEval(x2)
    else:
        return pg.siEval(x.lstrip('~')), None
Beispiel #3
0
def stripUnits(x):
    if x is None or x == '-' or '?' in x:
        return [None]
    x = x.lstrip('~')
    x.replace('%', '')
    return [pg.siEval(x)]
Beispiel #4
0
def stripUnits(x):
    if x is None or x == '-' or '?' in x:
        return [None]
    x = x.lstrip('~')
    x.replace('%', '')  
    return [pg.siEval(x)]