Ignore:
Timestamp:
Feb 21, 2017 3:50:45 PM (5 years ago)
Author:
vondreele
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIstrMain.py

    r2713 r2717  
    237237    if dlg:
    238238        return True,Rvals
     239       
     240def phaseCheck(phaseVary,Phases,histogram):
     241    '''
     242    Removes unused parameters from phase varylist if phase not in histogram
     243    '''
     244    pIds = []
     245    for phase in Phases:
     246        if Phases[phase]['Histograms'][histogram]['Use']:
     247            pIds.append(str(Phases[phase]['pId']))
     248    return [item for item in phaseVary if item.split(':')[0] in pIds]
    239249
    240250def SeqRefine(GPXfile,dlg):
     
    300310            print("Error: not found!")
    301311            continue
     312        redphaseVary = phaseCheck(phaseVary,Phases,histogram)
    302313        Histo = {histogram:Histograms[histogram],}
    303314        hapVary,hapDict,controlDict = G2stIO.GetHistogramPhaseData(Phases,Histo,Print=False)
     
    305316        histVary,histDict,controlDict = G2stIO.GetHistogramData(Histo,False)
    306317        calcControls.update(controlDict)
    307         varyList = rbVary+phaseVary+hapVary+histVary
     318        varyList = rbVary+redphaseVary+hapVary+histVary
    308319        if not ihst:
    309320            # save the initial vary list, but without histogram numbers on parameters
Note: See TracChangeset for help on using the changeset viewer.