Changeset 5348
 Timestamp:
 Oct 14, 2022 10:56:05 AM (6 months ago)
 Location:
 trunk
 Files:

 2 edited
Legend:
 Unmodified
 Added
 Removed

trunk/GSASIIplot.py
r5346 r5348 11620 11620 Ndata = len(CLuDict['Files']) 11621 11621 neighD = [YM[i][i+1] for i in range(Ndata1)] 11622 Codes = copy.copy(CLuDict['codes']) 11623 if Codes is not None: 11624 Codes = np.where(Codes<0,5,Codes) 11622 11625 if CLuDict['CLuZ'] is None and CLuDict['plots'] == 'Dendrogram': 11623 11626 CLuDict['plots'] = 'All' … … 11641 11644 Plot.set_ylabel('dist to next',fontsize=12) 11642 11645 elif CLuDict['plots'] == '2D PCA': 11643 if C LuDict['codes']is not None:11646 if Codes is not None: 11644 11647 for ixyz,xyz in enumerate(XYZ.T): 11645 Plot.scatter(xyz[0],xyz[1],color=Colors[C LuDict['codes'][ixyz]],picker=True)11648 Plot.scatter(xyz[0],xyz[1],color=Colors[Codes[ixyz]],picker=True) 11646 11649 else: 11647 11650 for ixyz,xyz in enumerate(XYZ.T): … … 11651 11654 Plot.set_ylabel('PCA axis2',fontsize=12) 11652 11655 elif CLuDict['plots'] == '3D PCA': 11653 if C LuDict['codes']is not None:11656 if Codes is not None: 11654 11657 for ixyz,xyz in enumerate(XYZ.T): 11655 Plot.scatter(xyz[0],xyz[1],xyz[2],color=Colors[C LuDict['codes'][ixyz]],picker=True)11658 Plot.scatter(xyz[0],xyz[1],xyz[2],color=Colors[Codes[ixyz]],picker=True) 11656 11659 else: 11657 11660 for ixyz,xyz in enumerate(XYZ.T): … … 11674 11677 ax1.set_xlabel('Data set',fontsize=12) 11675 11678 ax1.set_ylabel('Data set',fontsize=12) 11676 if C LuDict['codes']is not None:11679 if Codes is not None: 11677 11680 for ixyz,xyz in enumerate(XYZ.T): 11678 ax2.scatter(xyz[0],xyz[1],color=Colors[C LuDict['codes'][ixyz]],picker=True)11681 ax2.scatter(xyz[0],xyz[1],color=Colors[Codes[ixyz]],picker=True) 11679 11682 else: 11680 11683 for ixyz,xyz in enumerate(XYZ.T): 
trunk/GSASIIseqGUI.py
r5345 r5348 1961 1961 elif ClusData['OutMethod'] == 'Local Outlier Factor': 1962 1962 ClusData['codes'] = SKN.LocalOutlierFactor().fit_predict(ClusData['DataMatrix']) 1963 ClusData['codes'] = np.where(ClusData['codes']>0,1,5) #red(in) or black(out)1964 1963 wx.CallAfter(UpdateClusterAnalysis,G2frame,ClusData,shoNum) 1965 1964
Note: See TracChangeset
for help on using the changeset viewer.