project_name
string
class_name
string
class_modifiers
string
class_implements
int64
class_extends
int64
function_name
string
function_body
string
cyclomatic_complexity
int64
NLOC
int64
num_parameter
int64
num_token
int64
num_variable
int64
start_line
int64
end_line
int64
function_index
int64
function_params
string
function_variable
string
function_return_type
string
function_body_line_type
string
function_num_functions
int64
function_num_lines
int64
outgoing_function_count
int64
outgoing_function_names
string
incoming_function_count
int64
incoming_function_names
string
lexical_representation
string
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotXYZ
def PlotXYZ(G2frame,XY,Z,labelX='X',labelY='Y',newPlot=False,Title='',zrange=None,color=None,buttonHandler=None):'''simple contour plot of xyz data:param wx.Frame G2frame: The main GSAS-II tree "window":param list XY: a list of X,Y arrays:param list Z: a list of Z values for each X,Y pair:param str labelX: label for X-...
8
51
10
432
20
2,576
2,698
2,576
null
['Xmax', 'Ymax', 'xylim', 'newPlot', 'Nxy', 'Ymin', 'ix', 'iy', 'acolor', 'dlg', 'Xwd', 'Img', 'ypos', 'xpos', 'Ywd', 'Zmax', 'sel', 'Xmin', 'zrange', 'choice']
None
null
0
0
0
null
0
null
The function (PlotXYZ) defined within the public class called public.The function start at line 2576 and ends at 2698. It contains 51 lines of code and it has a cyclomatic complexity of 8. It takes 10 parameters, represented as [2576.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotXYZvect.OnMotion
def OnMotion(event):G2frame.G2plotNB.status.SetStatusText('',1)
1
2
1
17
0
2,711
2,712
2,711
null
[]
None
null
0
0
0
null
0
null
The function (PlotXYZvect.OnMotion) defined within the public class called public.The function start at line 2711 and ends at 2712. It contains 2 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotXYZvect
def PlotXYZvect(G2frame,X,Y,Z,R,labelX=r'X',labelY=r'Y',labelZ=r'Z',Title='',PlotName=None):''' To plot a quiver of quaternion vectors colored by the rotation:param wx.Frame G2frame: The main GSAS-II tree "window":param list X,Y,Z: list of X,Y,Z arrays:param list R: a list of rotations (0-90) for each X,Y,Z in degrees:...
5
33
10
349
7
2,701
2,744
2,701
null
['icolor', 'mcolors', 'X0', 'xyzlim', 'XYZlim', 'Y0', 'Z0']
None
null
0
0
0
null
0
null
The function (PlotXYZvect) defined within the public class called public.The function start at line 2701 and ends at 2744. It contains 33 lines of code and it has a cyclomatic complexity of 5. It takes 10 parameters, represented as [2701.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
Plot3dXYZ.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataG2frame.G2plotNB.status.SetStatusText('X =%.3f Y =%.4f'%(xpos,ypos),1)
2
5
1
36
0
2,749
2,753
2,749
null
[]
None
null
0
0
0
null
0
null
The function (Plot3dXYZ.OnMotion) defined within the public class called public.The function start at line 2749 and ends at 2753. It contains 5 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
Plot3dXYZ.OnKeyPress
def OnKeyPress(event):if event.key == 'g':mpl.rcParams['axes.grid'] = not mpl.rcParams['axes.grid']
2
3
1
26
0
2,755
2,757
2,755
null
[]
None
null
0
0
0
null
0
null
The function (Plot3dXYZ.OnKeyPress) defined within the public class called public.The function start at line 2755 and ends at 2757. It contains 3 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
Plot3dXYZ
def Plot3dXYZ(G2frame,nX,nY,Zdat,labelX=r'X',labelY=r'Y',labelZ=r'Z',newPlot=False,Title='',Centro=False):'''Creates a surface Plot for 3D vectors'''def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataG2frame.G2plotNB.status.SetStatusText('X =%.3f Y =%.4f'%(xpos,ypos),1)def...
9
37
10
423
10
2,747
2,797
2,747
null
['Z', 'Zmul', 'Y', 'ypos', 'X', 'xyzlim', 'XYZlim', 'xpos', 'PHI', 'PSI']
None
null
0
0
0
null
0
null
The function (Plot3dXYZ) defined within the public class called public.The function start at line 2747 and ends at 2797. It contains 37 lines of code and it has a cyclomatic complexity of 9. It takes 10 parameters, represented as [2747.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotAAProb.OnMotion
def OnMotion(event):xpos,ypos = event.xdata,event.ydataif xpos and xpos > 1.:if 0 <= xpos < len(resNames):resName = resNames[int(xpos+.5)-1]else:resName = ''SetCursor(Page)try:if 0 <= xpos < len(resNames):G2frame.G2plotNB.status.SetStatusText('Residue: %s score: %.2f'%(resName,ypos),1)except TypeError:G2frame.G2plotNB....
6
13
1
102
0
2,803
2,815
2,803
null
[]
None
null
0
0
0
null
0
null
The function (PlotAAProb.OnMotion) defined within the public class called public.The function start at line 2803 and ends at 2815. It contains 13 lines of code and it has a cyclomatic complexity of 6. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotAAProb.OnPick
def OnPick(event):xpos = event.mouseevent.xdataif xpos and pickHandler:xpos = int(xpos+.5)if 0 <= xpos < len(resNames):resName = resNames[xpos]else:resName = ''pickHandler(resName)
4
9
1
51
0
2,817
2,825
2,817
null
[]
None
null
0
0
0
null
0
null
The function (PlotAAProb.OnPick) defined within the public class called public.The function start at line 2817 and ends at 2825. It contains 9 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotAAProb.Draw
def Draw():global Plot1,Plot2Plot.clear()Plot.set_title(Title)Plot.set_axis_off()Plot1 = Page.figure.add_subplot(211)Plot1.set_ylabel(r'Error score 1',fontsize=14)Plot1.set_xlabel(r'Residue',fontsize=14)colors = list(np.where(np.array(Probs1)>thresh[0][1],'r','b'))resNums = np.arange(len(resNames))Plot1.bar(resNums,Pro...
5
24
0
293
0
2,827
2,850
2,827
null
[]
None
null
0
0
0
null
0
null
The function (PlotAAProb.Draw) defined within the public class called public.The function start at line 2827 and ends at 2850. It contains 24 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotAAProb
def PlotAAProb(G2frame,resNames,Probs1,Probs2,Title='',thresh=None,pickHandler=None):'Needs a description'def OnMotion(event):xpos,ypos = event.xdata,event.ydataif xpos and xpos > 1.:if 0 <= xpos < len(resNames):resName = resNames[int(xpos+.5)-1]else:resName = ''SetCursor(Page)try:if 0 <= xpos < len(resNames):G2frame.G...
1
9
7
73
6
2,800
2,855
2,800
null
['resName', 'colors', 'Plot1', 'Plot2', 'xpos', 'resNums']
None
null
0
0
0
null
0
null
The function (PlotAAProb) defined within the public class called public.The function start at line 2800 and ends at 2855. It contains 9 lines of code and it has a cyclomatic complexity of 1. It takes 7 parameters, represented as [2800.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStrain.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('d-spacing =%9.5f Azimuth =%9.3f'%(ypos,xpos),1)except TypeError:G2frame.G2plotNB.status.SetStatusText('Select Strain pattern first',1)
3
9
1
57
0
2,861
2,869
2,861
null
[]
None
null
0
0
0
null
0
null
The function (PlotStrain.OnMotion) defined within the public class called public.The function start at line 2861 and ends at 2869. It contains 9 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStrain
def PlotStrain(G2frame,data,newPlot=False):'''plot of strain data, used for diagnostic purposes'''def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('d-spacing =%9.5f Azimuth =%9.3f'%(ypos,xpos),1)except TypeError:G2...
5
32
3
319
6
2,858
2,902
2,858
null
['xylim', 'newPlot', 'ypos', 'colors', 'NC', 'xpos']
None
null
0
0
0
null
0
null
The function (PlotStrain) defined within the public class called public.The function start at line 2858 and ends at 2902. It contains 32 lines of code and it has a cyclomatic complexity of 5. It takes 3 parameters, represented as [2858.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotBarGraph.OnPageChanged
def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if PlotText == PlotName:PlotBarGraph(G2frame,Xarray,Xname,Title,PlotText)
2
4
1
42
0
2,909
2,912
2,909
null
[]
None
null
0
0
0
null
0
null
The function (PlotBarGraph.OnPageChanged) defined within the public class called public.The function start at line 2909 and ends at 2912. It contains 4 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotBarGraph.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('X =%9.3f Number =%9.3g'%(xpos,ypos),1)except TypeError:G2frame.G2plotNB.status.SetStatusText('Select %s first'%PlotName,1)
3
9
1
59
0
2,914
2,922
2,914
null
[]
None
null
0
0
0
null
0
null
The function (PlotBarGraph.OnMotion) defined within the public class called public.The function start at line 2914 and ends at 2922. It contains 9 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotBarGraph
def PlotBarGraph(G2frame,Xarray,Xname='',Yname='Number',Title='',PlotName=None,ifBinned=False,maxBins=None):''' does a vertical bar graph'''def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if PlotText == PlotName:PlotBarGraph(G2frame,Xarray,Xname,Title,PlotText)def ...
6
26
8
244
6
2,905
2,946
2,905
null
['Dbins', 'nBins', 'ypos', 'wid', 'PlotText', 'xpos']
None
null
0
0
0
null
0
null
The function (PlotBarGraph) defined within the public class called public.The function start at line 2905 and ends at 2946. It contains 26 lines of code and it has a cyclomatic complexity of 6. It takes 8 parameters, represented as [2905.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotNamedFloatHBarGraph.OnPageChanged
def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if PlotText == PlotName:PlotNamedFloatHBarGraph(G2frame,Xvals,Ynames,Xlabel,Ylabel,Title,PlotText)
2
4
1
46
0
2,953
2,956
2,953
null
[]
None
null
0
0
0
null
0
null
The function (PlotNamedFloatHBarGraph.OnPageChanged) defined within the public class called public.The function start at line 2953 and ends at 2956. It contains 4 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotNamedFloatHBarGraph.OnMotion
def OnMotion(event):if event.ydata is None:returnypos = int(event.ydata+.5)if ypos and ypos < len(Ynames):#avoid out of frame mouse positionSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('X =%s %s = %9.3g'%(Ynames[ypos],Xlabel,Xvals[ypos]),1)except TypeError:G2frame.G2plotNB.status.SetStatusText('Select %s fi...
5
10
1
83
0
2,958
2,967
2,958
null
[]
None
null
0
0
0
null
0
null
The function (PlotNamedFloatHBarGraph.OnMotion) defined within the public class called public.The function start at line 2958 and ends at 2967. It contains 10 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotNamedFloatHBarGraph
def PlotNamedFloatHBarGraph(G2frame,Xvals,Ynames,Xlabel='Value',Ylabel='',Title='',PlotName=None):''' does a horizintal bar graph'''def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if PlotText == PlotName:PlotNamedFloatHBarGraph(G2frame,Xvals,Ynames,Xlabel,Ylabel,Ti...
6
17
7
184
4
2,949
2,982
2,949
null
['Yvals', 'PlotText', 'ypos', 'colors']
None
null
0
0
0
null
0
null
The function (PlotNamedFloatHBarGraph) defined within the public class called public.The function start at line 2949 and ends at 2982. It contains 17 lines of code and it has a cyclomatic complexity of 6. It takes 7 parameters, represented as [2949.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDSizeDist.OnPageChanged
def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if 'Powder' in PlotText:G2pwpl.PlotPatterns(G2frame,plotType='SASD',newPlot=True)elif 'Size' in PlotText:PlotSASDSizeDist(G2frame)elif 'Pair' in PlotText:PlotSASDPairDist(G2frame)
4
8
1
62
0
2,988
2,995
2,988
null
[]
None
null
0
0
0
null
0
null
The function (PlotSASDSizeDist.OnPageChanged) defined within the public class called public.The function start at line 2988 and ends at 2995. It contains 8 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDSizeDist.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('diameter =%9.3f f(D) =%9.3g'%(xpos,ypos),1)except TypeError:G2frame.G2plotNB.status.SetStatusText('Select Size pattern first',1)
3
9
1
57
0
2,997
3,005
2,997
null
[]
None
null
0
0
0
null
0
null
The function (PlotSASDSizeDist.OnMotion) defined within the public class called public.The function start at line 2997 and ends at 3005. It contains 9 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDSizeDist
def PlotSASDSizeDist(G2frame):'Needs a description'def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if 'Powder' in PlotText:G2pwpl.PlotPatterns(G2frame,plotType='SASD',newPlot=True)elif 'Size' in PlotText:PlotSASDSizeDist(G2frame)elif 'Pair' in PlotText:PlotSASDPair...
7
31
1
310
7
2,985
3,034
2,985
null
['PatternId', 'ypos', 'colors', 'NC', 'PlotText', 'xpos', 'data']
None
null
0
0
0
null
0
null
The function (PlotSASDSizeDist) defined within the public class called public.The function start at line 2985 and ends at 3034. It contains 31 lines of code and it has a cyclomatic complexity of 7. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDPairDist.OnPageChanged
def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if 'Powder' in PlotText:G2pwpl.PlotPatterns(G2frame,plotType='SASD',newPlot=True)elif 'Size' in PlotText:PlotSASDSizeDist(G2frame)elif 'Pair' in PlotText:PlotSASDPairDist(G2frame)
4
8
1
62
0
3,040
3,047
3,040
null
[]
None
null
0
0
0
null
0
null
The function (PlotSASDPairDist.OnPageChanged) defined within the public class called public.The function start at line 3040 and ends at 3047. It contains 8 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDPairDist.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataSetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('pair dist =%9.3f f(D) =%9.3g'%(xpos,ypos),1)except TypeError:G2frame.G2plotNB.status.SetStatusText('Select Pair pattern first',1)
3
9
1
57
0
3,049
3,057
3,049
null
[]
None
null
0
0
0
null
0
null
The function (PlotSASDPairDist.OnMotion) defined within the public class called public.The function start at line 3049 and ends at 3057. It contains 9 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSASDPairDist
def PlotSASDPairDist(G2frame):'Needs a description'def OnPageChanged(event):PlotText = G2frame.G2plotNB.nb.GetPageText(G2frame.G2plotNB.nb.GetSelection())if 'Powder' in PlotText:G2pwpl.PlotPatterns(G2frame,plotType='SASD',newPlot=True)elif 'Size' in PlotText:PlotSASDSizeDist(G2frame)elif 'Pair' in PlotText:PlotSASDPair...
4
21
1
201
5
3,037
3,075
3,037
null
['PatternId', 'ypos', 'PlotText', 'xpos', 'data']
None
null
0
0
0
null
0
null
The function (PlotSASDPairDist) defined within the public class called public.The function start at line 3037 and ends at 3075. It contains 21 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotPowderLines.OnMotion
def OnMotion(event):global IndexFromxpos = event.xdataif xpos:#avoid out of frame mouse positionSetCursor(Page)G2frame.G2plotNB.status.SetStatusText('2-theta =%9.3f %s'%(xpos,IndxFrom),1)if G2frame.PickId and G2frame.GPXtree.GetItemText(G2frame.PickId) in ['Index Peak List','Unit Cells List']:found = []if len(G2frame.H...
6
18
1
177
0
3,083
3,100
3,083
null
[]
None
null
0
0
0
null
0
null
The function (PlotPowderLines.OnMotion) defined within the public class called public.The function start at line 3083 and ends at 3100. It contains 18 lines of code and it has a cyclomatic complexity of 6. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotPowderLines
def PlotPowderLines(G2frame,indexFrom=''):''' plotting of powder lines (i.e. no powder pattern) as sticks'''global Plot,IndxFromIndxFrom = indexFromdef OnMotion(event):global IndexFromxpos = event.xdataif xpos:#avoid out of frame mouse positionSetCursor(Page)G2frame.G2plotNB.status.SetStatusText('2-theta =%9.3f %s'%(xp...
4
25
2
241
11
3,078
3,122
3,078
null
['IndxFrom', 'PatternId', 'peaks', 'xmax', 'found', 'xmin', 'wid', 'delt', 'findx', 'xlim', 'xpos']
None
null
0
0
0
null
0
null
The function (PlotPowderLines) defined within the public class called public.The function start at line 3078 and ends at 3122. It contains 25 lines of code and it has a cyclomatic complexity of 4. It takes 2 parameters, represented as [3078.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotPeakWidths.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataG2frame.G2plotNB.status.SetStatusText('Q =%.3f%s %sQ/Q =%.4f'%(xpos,Angstr+Pwrm1,GkDelta,ypos),1)
2
5
1
42
0
3,135
3,139
3,135
null
[]
None
null
0
0
0
null
0
null
The function (PlotPeakWidths.OnMotion) defined within the public class called public.The function start at line 3135 and ends at 3139. It contains 5 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotPeakWidths.OnKeyPress
def OnKeyPress(event):if event.key == 'g':mpl.rcParams['axes.grid'] = not mpl.rcParams['axes.grid']elif event.key== 'e':G2frame.ErrorBars= not G2frame.ErrorBarselif event.key == 's':# write the function values (not peaks) onto a filedlg = wx.FileDialog(G2frame, 'Choose CSV file to write', G2G.GetExportPath(G2frame),wil...
10
27
1
260
0
3,141
3,168
3,141
null
[]
None
null
0
0
0
null
0
null
The function (PlotPeakWidths.OnKeyPress) defined within the public class called public.The function start at line 3141 and ends at 3168. It contains 27 lines of code and it has a cyclomatic complexity of 10. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotPeakWidths
def PlotPeakWidths(G2frame,PatternName=None):''' Plotting of instrument broadening terms as function of QSeen when "Instrument Parameters" chosen from powder pattern data tree.Parameter PatternName allows the PWDR to be referenced as a string rather thana wx tree item, defined in G2frame.PatternId.'''#sig = lambda Th,U...
32
257
2
2,684
64
3,125
3,439
3,125
null
['gf', 'Gp', 'xylim', 'sGp', 'item', 'Wp', 'sSp', 'sf', 'g', 'limits', 'tpd', 'ds', 'Sp', 'fp', 'Zf', 'yp', 'filename', 'Wf', 'dlg', 's', 'TreeItemText', 'sYp', 'negWarn', 'Yf', 'peakEsds', 'Qp', 'legend', 'Z', 'difC', 'Bf', 'Bp', 'Q', 'data', 'B', 'sp', 'Ap', 'isig', 'ypos', 'igam', 'fit', 'tth', 'Af', 'Yp', 'sBp', 'E...
None
null
0
0
0
null
0
null
The function (PlotPeakWidths) defined within the public class called public.The function start at line 3125 and ends at 3439. It contains 257 lines of code and it has a cyclomatic complexity of 32. It takes 2 parameters, represented as [3125.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotDeform
def PlotDeform(G2frame,general,atName,atType,deform,UVmat,radial,neigh):''' Plot deformation atoms & neighbors'''SHC = {}for item in deform:if 'Be' in radial and 'Sl' not in item[0]:if '<j0>' in item[0]:continueif 'kappa' in item[1]:kappa = item[1]['kappa'][0]for trm in item[1]:if 'D(' in trm:SHC[trm.replace('D','C')] ...
19
55
8
725
15
3,442
3,501
3,442
null
['kappa', 'p', 'Z', 'RAP', 'Y', 'plotType', 'X', 'color', 'XYZ', 'xyzlim', 'XYZlim', 'SHC', 'P', 'PHI', 'PSI']
None
null
0
0
0
null
0
null
The function (PlotDeform) defined within the public class called public.The function start at line 3442 and ends at 3501. It contains 55 lines of code and it has a cyclomatic complexity of 19. It takes 8 parameters, represented as [3442.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.OnPick
def OnPick(event):if 'Inv. pole figure' not in plotType:returnind = event.ind[0]h,k,l = RefSets[ind]msg = '%d,%d,%d=%.2f'%(h,k,l,Rmd[ind])Page.SetToolTipString(msg)
2
7
1
52
0
3,509
3,515
3,509
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.OnPick) defined within the public class called public.The function start at line 3509 and ends at 3515. It contains 7 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.rp2xyz
def rp2xyz(r,p):z = npcosd(r)xy = np.sqrt(1.-z**2)return xy*npcosd(p),xy*npsind(p),z
1
4
2
42
0
3,517
3,520
3,517
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.rp2xyz) defined within the public class called public.The function start at line 3517 and ends at 3520. It contains 4 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [3517.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.OnMotion
def OnMotion(event):if 'Inv. pole figure' not in plotType:returnif event.xdata and event.ydata: #avoid out of frame errorsxpos = event.xdataypos = event.ydatar = xpos**2+ypos**2if r <= 1.0:if 'Eq. area' in plotType:r,p = 2.*npasind(np.sqrt(r)*sq2),npatan2d(xpos,ypos)else:r,p = 2.*npatand(np.sqrt(r)),npatan2d(xpos,ypos)...
8
22
1
220
0
3,522
3,543
3,522
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.OnMotion) defined within the public class called public.The function start at line 3522 and ends at 3543. It contains 22 lines of code and it has a cyclomatic complexity of 8. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.uniaxCalc
def uniaxCalc(xyz,iso,aniso,axes):Z = np.array(axes)cp = abs(np.dot(xyz,Z))sp = np.sqrt(1.-cp**2)R = iso*aniso/np.sqrt((iso*cp)**2+(aniso*sp)**2)return R*xyz*diam
1
6
4
77
0
3,595
3,600
3,595
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.uniaxCalc) defined within the public class called public.The function start at line 3595 and ends at 3600. It contains 6 lines of code and it has a cyclomatic complexity of 1. It takes 4 parameters, represented as [3595.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.ellipseCalc
def ellipseCalc(xyz,E,R):XYZ = xyz*E.Treturn np.inner(XYZ.T,R)*diam
1
3
3
29
0
3,615
3,617
3,615
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.ellipseCalc) defined within the public class called public.The function start at line 3615 and ends at 3617. It contains 3 lines of code and it has a cyclomatic complexity of 1. It takes 3 parameters, represented as [3615.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO.genMustrain
def genMustrain(xyz,SGData,A,Shkl):uvw = np.inner(Amat.T,xyz)Strm = np.array(G2spc.MustrainCoeff(uvw,SGData))Sum = np.sum(np.multiply(Shkl,Strm))Sum = np.where(Sum > 0.01,Sum,0.01)Sum = np.sqrt(Sum)return Sum*xyz
1
7
4
83
0
3,631
3,637
3,631
null
[]
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO.genMustrain) defined within the public class called public.The function start at line 3631 and ends at 3637. It contains 7 lines of code and it has a cyclomatic complexity of 1. It takes 4 parameters, represented as [3631.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSizeStrainPO
def PlotSizeStrainPO(G2frame,data,hist=''):'''Plot 3D mustrain/size/preferred orientation figure. In this instance data is for a phase'''def OnPick(event):if 'Inv. pole figure' not in plotType:returnind = event.ind[0]h,k,l = RefSets[ind]msg = '%d,%d,%d=%.2f'%(h,k,l,Rmd[ind])Page.SetToolTipString(msg)def rp2xyz(r,p):z =...
48
212
3
2,244
63
3,505
3,779
3,505
null
['Sum', 'Refs', 'npts', 'ODFln', 'refSets', 'Phi', 'XYZ', 'PH', 'cell', 'Type', 'refSet', 'z', 'p', 'msg', 'Shkl', 'lut', 'useList', 'Ops', 'RefData', 'R', 'SHCoef', 'obsRMD', 'rId', 'RefSets', 'plotDict', 'cp', 'xyzlim', 'coeff', 'acolor', 'uvw', 'ind', 'SGData', 'diam', 'ns', 'ipf', 'Beta', 'CS', 'r', 'Z', 'sp', 'Img...
None
null
0
0
0
null
0
null
The function (PlotSizeStrainPO) defined within the public class called public.The function start at line 3505 and ends at 3779. It contains 212 lines of code and it has a cyclomatic complexity of 48. It takes 3 parameters, represented as [3505.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTexture.rp2xyz
def rp2xyz(r,p):z = npcosd(r)xy = np.sqrt(1.-z**2)return xy*npsind(p),xy*npcosd(p),z
1
4
2
42
0
3,803
3,806
3,803
null
[]
None
null
0
0
0
null
0
null
The function (PlotTexture.rp2xyz) defined within the public class called public.The function start at line 3803 and ends at 3806. It contains 4 lines of code and it has a cyclomatic complexity of 1. It takes 2 parameters, represented as [3803.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTexture.OnMotion
def OnMotion(event):SHData = data['General']['SH Texture']if event.xdata and event.ydata: #avoid out of frame errorsxpos = event.xdataypos = event.ydataif 'Inverse' in SHData['PlotType']:r = xpos**2+ypos**2if r <= 1.0:if 'equal' in G2frame.Projection:r,p = 2.*npasind(np.sqrt(r)*sq2),npatan2d(xpos,ypos)else:r,p = 2.*npa...
9
29
1
352
0
3,808
3,839
3,808
null
[]
None
null
0
0
0
null
0
null
The function (PlotTexture.OnMotion) defined within the public class called public.The function start at line 3808 and ends at 3839. It contains 29 lines of code and it has a cyclomatic complexity of 9. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTexture.OnPick
def OnPick(event):pick = event.artistDettext = pick.get_gid()Page.SetToolTipString(Dettext)
1
4
1
23
0
3,841
3,844
3,841
null
[]
None
null
0
0
0
null
0
null
The function (PlotTexture.OnPick) defined within the public class called public.The function start at line 3841 and ends at 3844. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTexture
def PlotTexture(G2frame,data,Start=False):'''Pole figure, inverse pole figure plotting.dict generalData contains all phase info needed which is in data'''shModels = ['cylindrical','none','shear - 2/m','rolling - mmm']SamSym = dict(zip(shModels,['0','-1','2/m','mmm']))#PatternId = G2frame.PatternIdgeneralData = data['Ge...
26
140
3
1,746
43
3,782
3,970
3,782
null
['Ydet', 'npts', 'ODFln', 'gam', 'pf', 'PH', 'cell', 'z', 'SamSym', 'SHCoef', 'R', 'pick', 'acolor', 'xyzlim', 'SGData', 'ipf', 'IODFln', 'CS', 'r', 'Z', 'Dettext', 'Img', 'xyz', 'ypos', 'GAM', 'SHData', 'Xdet', 'Rdet', 'xy', 'pName', 'xpos', 'textureData', 'PX', 'shModels', 'PSI', 'sq2', 'Y', 'generalData', 'psi', 'XY...
None
null
0
0
0
null
0
null
The function (PlotTexture) defined within the public class called public.The function start at line 3782 and ends at 3970. It contains 140 lines of code and it has a cyclomatic complexity of 26. It takes 3 parameters, represented as [3782.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ModulationPlot.OnMotion
def OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataix = int(round(xpos*10))iy = int(round((Slab.shape[0]-1)*(ypos+0.5-Off*0.005)))SetCursor(Page)try:G2frame.G2plotNB.status.SetStatusText('t =%9.3f %s =%9.3f %s=%9.3f'%(xpos,GkDelta+Ax,ypos,Gkrho,Slab[iy,ix]/8.),1)#GSASIIpat...
3
11
1
124
0
3,980
3,991
3,980
null
[]
None
null
0
0
0
null
0
null
The function (ModulationPlot.OnMotion) defined within the public class called public.The function start at line 3980 and ends at 3991. It contains 11 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ModulationPlot.OnPlotKeyPress
def OnPlotKeyPress(event):global Off,Atom,Axif event.key == '0':Off = 0elif event.key in ['+','=']:Off += 1elif event.key == '-':Off -= 1elif event.key in ['l','r',] and mapData['Flip']:roll = 1ifevent.key == 'l':roll = -1rho = Map['rho']Map['rho'] = np.roll(rho,roll,axis=3)wx.CallAfter(ModulationPlot,G2frame,data,Atom...
7
15
1
115
0
3,993
4,007
3,993
null
[]
None
null
0
0
0
null
0
null
The function (ModulationPlot.OnPlotKeyPress) defined within the public class called public.The function start at line 3993 and ends at 4007. It contains 15 lines of code and it has a cyclomatic complexity of 7. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ModulationPlot
def ModulationPlot(G2frame,data,atom,ax,off=0):'Needs a description'global Off,Atom,Ax,Slab,OffOff = offAtom = atomAx = axdef OnMotion(event):xpos = event.xdataif xpos:#avoid out of frame mouse positionypos = event.ydataix = int(round(xpos*10))iy = int(round((Slab.shape[0]-1)*(ypos+0.5-Off*0.005)))SetCursor(Page)try:G2...
15
83
5
958
30
3,973
4,083
3,973
null
['Title', 'Map', 'MapType', 'wave', 'rho', 'ix', 'Off', 'iy', 'acolor', 'mapData', 'hdx', 'ib', 'Spos', 'ccof', 'slab', 'Atom', 'Ax', 'ypos', 'rhoSize', 'roll', 'XYZmax', 'xpos', 'Doff', 'scof', 'waveType', 'tau', 'Slab', 'atxyz', 'General', 'Tminmax']
None
null
0
0
0
null
0
null
The function (ModulationPlot) defined within the public class called public.The function start at line 3973 and ends at 4083. It contains 83 lines of code and it has a cyclomatic complexity of 15. It takes 5 parameters, represented as [3973.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotCovariance.OnPlotKeyPress
def OnPlotKeyPress(event):if event.key == 's':choice = [m for m in mpl.cm.datad.keys()]+['GSPaired','GSPaired_r',] # if not m.endswith("_r")choice.sort()dlg = wx.SingleChoiceDialog(G2frame,'Select','Color scheme',choice)if dlg.ShowModal() == wx.ID_OK:sel = dlg.GetSelection()G2frame.VcovColor = choice[sel]else:G2frame.V...
11
38
1
355
0
4,091
4,128
4,091
null
[]
None
null
0
0
0
null
0
null
The function (PlotCovariance.OnPlotKeyPress) defined within the public class called public.The function start at line 4091 and ends at 4128. It contains 38 lines of code and it has a cyclomatic complexity of 11. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotCovariance.OnMotion
def OnMotion(event):if event.button:ylim = imgAx.get_ylim()yBeg,yFin = max(0,int(ylim[0])),min(nVar,int(ylim[1])+1)step = int((ylim[1]-ylim[0])//8)if step:imgAx.set_yticks(np.arange(nVar)[yBeg:yFin:step])imgAx.set_yticklabels(Page.varyList[yBeg:yFin:step])else:imgAx.set_yticks(np.arange(nVar)[yBeg:yFin])imgAx.set_ytick...
9
25
1
295
0
4,130
4,154
4,130
null
[]
None
null
0
0
0
null
0
null
The function (PlotCovariance.OnMotion) defined within the public class called public.The function start at line 4130 and ends at 4154. It contains 25 lines of code and it has a cyclomatic complexity of 9. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotCovariance
def PlotCovariance(G2frame,Data,Cube=False):'''Plots the covariance matrix. Also shows values for parametersand their standard uncertainties (esd's) or the correlation betweenvariables.'''def OnPlotKeyPress(event):if event.key == 's':choice = [m for m in mpl.cm.datad.keys()]+['GSPaired','GSPaired_r',] # if not m.endswi...
8
53
3
484
20
4,086
4,206
4,086
null
['llen', 'msg', 'title', 'covMatrix', 'step', 'stop', 'acolor', 'dlg', 'nVar', 'covFile', 'Img', 'ypos', 'name', 'imgAx', 'xpos', 'ylim', 'value', 'sel', 'choice', 'xvar']
None
null
0
0
0
null
0
null
The function (PlotCovariance) defined within the public class called public.The function start at line 4086 and ends at 4206. It contains 53 lines of code and it has a cyclomatic complexity of 8. It takes 3 parameters, represented as [4086.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTorsion.OnPick
def OnPick(event):ind = event.ind[0]msg = 'atoms:'+names[ind]Page.SetToolTipString(msg)try:page = G2frame.phaseDisplay.GetSelection()except:returnif G2frame.restrBook.GetPageText(page) == 'Torsion restraints':torGrid = G2frame.restrBook.GetPage(page).TorsionstorGrid.ClearSelection()for row in range(torGrid.GetNumberRow...
5
15
1
108
0
4,221
4,235
4,221
null
[]
None
null
0
0
0
null
0
null
The function (PlotTorsion.OnPick) defined within the public class called public.The function start at line 4221 and ends at 4235. It contains 15 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTorsion.OnMotion
def OnMotion(event):if event.xdata and event.ydata: #avoid out of frame errorsxpos = event.xdataypos = event.ydatamsg = 'torsion,energy: %5.3f %5.3f'%(xpos,ypos)Page.SetToolTipString(msg)
3
6
1
39
0
4,237
4,242
4,237
null
[]
None
null
0
0
0
null
0
null
The function (PlotTorsion.OnMotion) defined within the public class called public.The function start at line 4237 and ends at 4242. It contains 6 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTorsion
def PlotTorsion(G2frame,phaseName,Torsion,TorName,Names=[],Angles=[],Coeff=[]):'needs a doc string'global namesnames = Namessum = np.sum(Torsion)torsion = np.log(2*Torsion+1.)/sumtMin = np.min(torsion)tMax = np.max(torsion)torsion = 3.*(torsion-tMin)/(tMax-tMin)X = np.linspace(0.,360.,num=45)def OnPick(event):ind = eve...
7
33
7
343
15
4,209
4,265
4,209
null
['tMax', 'tMin', 'torsion', 'ypos', 'names', 'X', 'torGrid', 'X2', 'Y2', 'ind', 'xpos', 'Eval', 'msg', 'page', 'sum']
None
null
0
0
0
null
0
null
The function (PlotTorsion) defined within the public class called public.The function start at line 4209 and ends at 4265. It contains 33 lines of code and it has a cyclomatic complexity of 7. It takes 7 parameters, represented as [4209.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotRama.OnPlotKeyPress
def OnPlotKeyPress(event):if event.key == 's':choice = [m for m in mpl.cm.datad.keys()]+['GSPaired','GSPaired_r',] # if not m.endswith("_r")choice.sort()dlg = wx.SingleChoiceDialog(G2frame,'Select','Color scheme',choice)if dlg.ShowModal() == wx.ID_OK:sel = dlg.GetSelection()G2frame.RamaColor = choice[sel]else:G2frame.R...
4
12
1
109
0
4,279
4,290
4,279
null
[]
None
null
0
0
0
null
0
null
The function (PlotRama.OnPlotKeyPress) defined within the public class called public.The function start at line 4279 and ends at 4290. It contains 12 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotRama.OnPick
def OnPick(event):ind = event.ind[0]msg = 'atoms:'+names[ind]Page.SetToolTipString(msg)try:page = G2frame.restrBook.GetSelection()except:returnif G2frame.restrBook.GetPageText(page) == 'Ramachandran restraints':ramaGrid = G2frame.restrBook.GetPage(page).RamasramaGrid.ClearSelection()for row in range(ramaGrid.GetNumberR...
5
15
1
108
0
4,292
4,306
4,292
null
[]
None
null
0
0
0
null
0
null
The function (PlotRama.OnPick) defined within the public class called public.The function start at line 4292 and ends at 4306. It contains 15 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotRama.OnMotion
def OnMotion(event):if event.xdata and event.ydata: #avoid out of frame errorsxpos = event.xdataypos = event.ydatamsg = 'phi/psi: %5.3f %5.3f'%(xpos,ypos)Page.SetToolTipString(msg)
3
6
1
39
0
4,308
4,313
4,308
null
[]
None
null
0
0
0
null
0
null
The function (PlotRama.OnMotion) defined within the public class called public.The function start at line 4308 and ends at 4313. It contains 6 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotRama
def PlotRama(G2frame,phaseName,Rama,RamaName,Names=[],PhiPsi=[],Coeff=[]):'needs a doc string'global namesnames = Namesrama = np.log(2*Rama+1.)rama = np.reshape(rama,(45,45))global Phi,PsiPhi = []Psi = []def OnPlotKeyPress(event):if event.key == 's':choice = [m for m in mpl.cm.datad.keys()]+['GSPaired','GSPaired_r',] #...
11
54
7
650
17
4,268
4,357
4,268
null
['ramaGrid', 'Z', 'rama', 'xpos', 'Img', 'ypos', 'names', 'sel', 'Phi', 'acolor', 'PhiPsi', 'dlg', 'ind', 'choice', 'Psi', 'msg', 'page']
None
null
0
0
0
null
0
null
The function (PlotRama) defined within the public class called public.The function start at line 4268 and ends at 4357. It contains 54 lines of code and it has a cyclomatic complexity of 11. It takes 7 parameters, represented as [4268.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSelectedSequence.OnMotion
def OnMotion(event):if event.xdata and event.ydata: #avoid out of frame errorsxpos = event.xdataypos = event.ydatamsg = '%5.3f %.6g'%(xpos,ypos)Page.SetToolTipString(msg)
3
6
1
39
0
4,374
4,379
4,374
null
[]
None
null
0
0
0
null
0
null
The function (PlotSelectedSequence.OnMotion) defined within the public class called public.The function start at line 4374 and ends at 4379. It contains 6 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSelectedSequence.OnKeyPress
def OnKeyPress(event):global Title,xLabel,yLabelif event.key == 's':G2frame.seqXaxis = G2frame.seqXselect()elif event.key == 't':dlg = G2G.MultiStringDialog(G2frame,'Set titles & labels',[' Title ',' x-Label ',' y-Label '],[Title,xLabel,yLabel])if dlg.Show():Title,xLabel,yLabel = dlg.GetValues()dlg.Destroy()elif event....
5
13
1
104
0
4,381
4,393
4,381
null
[]
None
null
0
0
0
null
0
null
The function (PlotSelectedSequence.OnKeyPress) defined within the public class called public.The function start at line 4381 and ends at 4393. It contains 13 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSelectedSequence.SeqDraw
def SeqDraw():global Title,xLabel,yLabelPlot=Page.figure.gca()G2frame.G2plotNB.status.SetStatusText('press L to toggle lines, S to select X axis, T to change titles (reselect column to show?)',1)Plot.clear()#colors=['b','g','r','c','m','k']colors = ['xkcd:blue','xkcd:red','xkcd:green','xkcd:cyan','xkcd:magenta','xkcd:b...
22
68
0
522
0
4,395
4,466
4,395
null
[]
None
null
0
0
0
null
0
null
The function (PlotSelectedSequence.SeqDraw) defined within the public class called public.The function start at line 4395 and ends at 4466. It contains 68 lines of code and it has a cyclomatic complexity of 22. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotSelectedSequence
def PlotSelectedSequence(G2frame,ColumnList,TableGet,SelectX,fitnum=None,fitvals=None):'''Plot a result from a sequential refinement:param wx.Frame G2frame: The main GSAS-II tree "window":param list ColumnList: list of int values corresponding to columnsselected as y values:param function TableGet: a function that take...
5
28
6
170
21
4,361
4,491
4,361
null
['Title', 'Ncol', 'msg', 'Xnew', 'dlg', 'label', 'Ynew', 'Ysnew', 'xLabel', 'Plot', 'uselist', 'yLabel', 'ypos', 'NC', 'xName', 'xpos', 'gotsig', 'Y', 'colors', 'sig', 'X']
None
null
0
0
0
null
0
null
The function (PlotSelectedSequence) defined within the public class called public.The function start at line 4361 and ends at 4491. It contains 28 lines of code and it has a cyclomatic complexity of 5. It takes 6 parameters, represented as [4361.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotExposedImage
def PlotExposedImage(G2frame,newPlot=False,event=None):'''General access module for 2D image plotting'''plotNo = G2frame.G2plotNB.nb.GetSelection()if plotNo < 0: return # no plotsif G2frame.G2plotNB.nb.GetPageText(plotNo) == '2D Powder Image':PlotImage(G2frame,newPlot,event,newImage=True)elif G2frame.G2plotNB.nb.GetPag...
4
7
3
79
1
4,494
4,502
4,494
null
['plotNo']
None
null
0
0
0
null
0
null
The function (PlotExposedImage) defined within the public class called public.The function start at line 4494 and ends at 4502. It contains 7 lines of code and it has a cyclomatic complexity of 4. It takes 3 parameters, represented as [4494.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
OnStartMask
def OnStartMask(G2frame):'''Initiate the start of a Frame or Polygon map, etc.Called from a menu command (GSASIIimgGUI) or from OnImPlotKeyPress.Variable G2frame.MaskKey contains a single letter ('f' or 'p', etc.) thatdetermines what type of mask is created.:param wx.Frame G2frame: The main GSAS-II tree "window"'''Mask...
9
37
1
447
1
4,504
4,548
4,504
null
['Masks']
None
null
0
0
0
null
0
null
The function (OnStartMask) defined within the public class called public.The function start at line 4504 and ends at 4548. It contains 37 lines of code and it has a cyclomatic complexity of 9. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
OnStartNewDzero
def OnStartNewDzero(G2frame):'''Initiate the start of adding a new d-zero to a strain data set:param wx.Frame G2frame: The main GSAS-II tree "window":param str eventkey: a single letter ('a') thattriggers the addition of a d-zero.'''G2frame.GetStatusBar().SetStatusText('Add strain ring active - LB pick d-zero value',0)...
1
5
1
48
1
4,550
4,560
4,550
null
['data']
None
null
0
0
0
null
0
null
The function (OnStartNewDzero) defined within the public class called public.The function start at line 4550 and ends at 4560. It contains 5 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ToggleMultiSpotMask
def ToggleMultiSpotMask(G2frame):'''Turns on and off MultiSpot selection mode; displays a subtitle on plotthe is cleared by the next PlotImage call'''new,plotNum,Page,Plot,lim = G2frame.G2plotNB.FindPlotTab('2D Powder Image','mpl',newImage=False)if G2frame.MaskKey == 's':G2frame.MaskKey = ''Page.Choice[-1] = 's: start ...
2
11
1
106
0
4,562
4,575
4,562
null
[]
None
null
0
0
0
null
0
null
The function (ToggleMultiSpotMask) defined within the public class called public.The function start at line 4562 and ends at 4575. It contains 11 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ShowSpotMaskInfo
def ShowSpotMaskInfo(G2frame,Page):if G2frame.MaskKey == 's':Page.figure.suptitle('Multiple spot mode on (size={}), press s or right-click to end'.format(G2frame.spotSize),color='r',fontweight='bold')else:Page.figure.suptitle('New spot size={}'.format(G2frame.spotSize), color='r',fontweight='bold')Page.canvas.draw()
2
8
2
69
0
4,577
4,584
4,577
null
[]
None
null
0
0
0
null
0
null
The function (ShowSpotMaskInfo) defined within the public class called public.The function start at line 4577 and ends at 4584. It contains 8 lines of code and it has a cyclomatic complexity of 2. It takes 2 parameters, represented as [4577.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
ComputeArc
def ComputeArc(angI,angO,wave,azm0=0,azm1=362):'''Computes arc/ring arrays in with inner and outer radii from angI,angOand beginning and ending azimuths azm0,azm1 (optional).Returns the inner and outer ring/arc arrays.'''Dsp = lambda tth,wave: wave/(2.*npsind(tth/2.))xy1 = []xy2 = []aR = [azm0,azm1,max(3,int(0.5+azm1-a...
5
15
5
186
6
4,586
4,604
4,586
null
['XY', 'Azm', 'aR', 'Dsp', 'xy1', 'xy2']
None
null
0
0
0
null
0
null
The function (ComputeArc) defined within the public class called public.The function start at line 4586 and ends at 4604. It contains 15 lines of code and it has a cyclomatic complexity of 5. It takes 5 parameters, represented as [4586.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
UpdatePolygon
def UpdatePolygon(pick,event,polygon):'''Update a polygon (or frame) in response to the location of the mouse.Delete the selected point if moved on top of another.With right button add a point after the current button.'''Xpos,Ypos = [event.xdata,event.ydata]if event.button == 1:# find distance to closest point other th...
6
14
3
165
3
4,606
4,624
4,606
null
['dlist', 'cp', 'dmin']
None
null
0
0
0
null
0
null
The function (UpdatePolygon) defined within the public class called public.The function start at line 4606 and ends at 4624. It contains 14 lines of code and it has a cyclomatic complexity of 6. It takes 3 parameters, represented as [4606.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.OnImMotion
def OnImMotion(event):if not Page:returnPage.SetToolTipString('')sizexy = Data['size']if event.xdata and event.ydata and len(G2frame.ImageZ): #avoid out of frame errorsPage.SetToolTipString('%8.2f %8.2fmm'%(event.xdata,event.ydata))SetCursor(Page)item = G2frame.itemPickedpixelSize = Data['pixelSize']scalex = 1000./pixe...
20
51
1
518
0
4,663
4,713
4,663
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.OnImMotion) defined within the public class called public.The function start at line 4663 and ends at 4713. It contains 51 lines of code and it has a cyclomatic complexity of 20. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.OnImPlotKeyRelease
def OnImPlotKeyRelease(event):if event.key == 'shift':G2frame.ShiftDown = False
2
3
1
17
0
4,715
4,717
4,715
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.OnImPlotKeyRelease) defined within the public class called public.The function start at line 4715 and ends at 4717. It contains 3 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.OnImPlotKeyPress
def OnImPlotKeyPress(event):try:treeItem = G2frame.GPXtree.GetItemText(G2frame.PickId)except TypeError:returnif treeItem == 'Masks':if event.key in [str(i) for i in range(10)]+['.']:G2frame.spotString += event.keyreturnelif G2frame.spotString:try:size = float(G2frame.spotString)G2frame.spotSize = sizeprint('Spot size s...
38
118
1
962
0
4,719
4,838
4,719
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.OnImPlotKeyPress) defined within the public class called public.The function start at line 4719 and ends at 4838. It contains 118 lines of code and it has a cyclomatic complexity of 38. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.PlotImage.OnImPick.OnDragIntBound
def OnDragIntBound(event):'Respond to the dragging of one of the integration boundaries'if event.xdata is None or event.ydata is None:# mouse is outside window. Could abort the movement,# for now ignore the movement until it moves back inreturntth,azm,dsp = G2img.GetTthAzmDsp2(event.xdata,event.ydata,Data)itemPicked = ...
25
81
1
814
0
4,843
4,930
4,843
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.PlotImage.OnImPick.OnDragIntBound) defined within the public class called public.The function start at line 4843 and ends at 4930. It contains 81 lines of code and it has a cyclomatic complexity of 25. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.PlotImage.OnImPick.OnDragMask
def OnDragMask(event):'Respond to the dragging of a mask'if event.xdata is None or event.ydata is None:# mouse is outside window. Could abort the movement,# for now ignore the movement until it moves back inreturnXpos,Ypos = [event.xdata,event.ydata]#if Page.toolbar._active: return # zoom/pan selectedPage.canvas.restor...
28
129
1
1,271
0
4,932
5,064
4,932
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.PlotImage.OnImPick.OnDragMask) defined within the public class called public.The function start at line 4932 and ends at 5064. It contains 129 lines of code and it has a cyclomatic complexity of 28. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.OnImPick
def OnImPick(event):'A object has been picked'def OnDragIntBound(event):'Respond to the dragging of one of the integration boundaries'if event.xdata is None or event.ydata is None:# mouse is outside window. Could abort the movement,# for now ignore the movement until it moves back inreturntth,azm,dsp = G2img.GetTthAzmD...
14
46
1
382
0
4,840
5,110
4,840
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.OnImPick) defined within the public class called public.The function start at line 4840 and ends at 5110. It contains 46 lines of code and it has a cyclomatic complexity of 14. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage.OnImRelease
def OnImRelease(event):'''Called when the mouse is released inside an image plot window'''global Pagetry:treeItem = G2frame.GPXtree.GetItemText(G2frame.PickId)except TypeError:returnif Data.get('linescan',[False,0.])[0]:Page.xlim1 = Plot1.get_xlim()new,plotNum,Page,Plot,lim = G2frame.G2plotNB.FindPlotTab('2D Powder Ima...
82
251
1
2,280
0
5,112
5,374
5,112
null
[]
None
null
0
0
0
null
0
null
The function (PlotImage.OnImRelease) defined within the public class called public.The function start at line 5112 and ends at 5374. It contains 251 lines of code and it has a cyclomatic complexity of 82. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotImage
def PlotImage(G2frame,newPlot=False,event=None,newImage=True):'''Plot of 2D detector images as contoured plot. Also plot calibration ellipses,masks, etc. Plots whatever is in G2frame.ImageZ:param wx.Frame G2frame: main GSAS-II frame:param bool newPlot: if newPlot is True, the plot is reset (zoomed out, etc.):param even...
88
341
4
3,572
97
4,626
5,707
4,626
null
['Int', 'rings', 'angO', 'xypos', 'Zlim', 'color', 'J', 'AzmthOff', 'itemNum', 'ellO', 'Nazm', 'ang', 'r', 'LRAzim', 'x', 'scalex', 'Xpix', 'xlim', 'pickType', 'StrSta', 'artist', 'xpix', 'dspI', 'colors', 'sig', 'angI', 'spot', 'Title', 'IOtth', 'darc', 'sizexy', 'N', 'ImMax', 'xyI', 'dlg', 'spotnum', 'ellI', 'Azm', '...
None
null
0
0
0
null
0
null
The function (PlotImage) defined within the public class called public.The function start at line 4626 and ends at 5707. It contains 341 lines of code and it has a cyclomatic complexity of 88. It takes 4 parameters, represented as [4626.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotIntegration.OnMotion
def OnMotion(event):Page.SetToolTipString('')SetCursor(Page)azm = event.ydatatth = event.xdataif azm and tth:G2frame.G2plotNB.status.SetStatusText(\'Detector 2-th =%9.3fdeg, azm = %7.2fdeg'%(tth,azm),1)
3
8
1
49
0
5,714
5,721
5,714
null
[]
None
null
0
0
0
null
0
null
The function (PlotIntegration.OnMotion) defined within the public class called public.The function start at line 5714 and ends at 5721. It contains 8 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotIntegration
def PlotIntegration(G2frame,newPlot=False,event=None):'''Plot of 2D image after image integration with 2-theta and azimuth as coordinates'''def OnMotion(event):Page.SetToolTipString('')SetCursor(Page)azm = event.ydatatth = event.xdataif azm and tth:G2frame.G2plotNB.status.SetStatusText(\'Detector 2-th =%9.3fdeg, azm = ...
4
32
3
295
9
5,710
5,759
5,710
null
['xylim', 'Img', 'azm', 'ysc', 'Data', 'acolor', 'image', 'xsc', 'tth']
None
null
0
0
0
null
0
null
The function (PlotIntegration) defined within the public class called public.The function start at line 5710 and ends at 5759. It contains 32 lines of code and it has a cyclomatic complexity of 4. It takes 3 parameters, represented as [5710.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotRawImage
def PlotRawImage(G2frame,image,label,newPlot=False):'''Plot an image without axes etc.'''new,plotNum,Page,Plot,lim = G2frame.G2plotNB.FindPlotTab(label,'mpl')Plot.remove() # delete original axesPlot = Page.figure.add_axes([0.0, 0.0, 1., 1.]) # fill page & don't showPlot.axis('off')Plot.imshow(image)Page.canvas.draw()
1
7
4
82
1
5,762
5,770
5,762
null
['Plot']
None
null
0
0
0
null
0
null
The function (PlotRawImage) defined within the public class called public.The function start at line 5762 and ends at 5770. It contains 7 lines of code and it has a cyclomatic complexity of 1. It takes 4 parameters, represented as [5762.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTRImage.OnMotion
def OnMotion(event):Page.SetToolTipString('')SetCursor(Page)azm = event.xdatatth = event.ydataif azm and tth:G2frame.G2plotNB.status.SetStatusText(\'Detector 2-th =%9.3fdeg, azm = %7.2fdeg'%(tth,azm),1)
3
8
1
49
0
5,777
5,784
5,777
null
[]
None
null
0
0
0
null
0
null
The function (PlotTRImage.OnMotion) defined within the public class called public.The function start at line 5777 and ends at 5784. It contains 8 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotTRImage
def PlotTRImage(G2frame,tax,tay,taz,newPlot=False):'''a test plot routine - not normally used'''def OnMotion(event):Page.SetToolTipString('')SetCursor(Page)azm = event.xdatatth = event.ydataif azm and tth:G2frame.G2plotNB.status.SetStatusText(\'Detector 2-th =%9.3fdeg, azm = %7.2fdeg'%(tth,azm),1)new,plotNum,Page,Plot,...
11
51
5
540
11
5,773
5,834
5,773
null
['IOtth', 'rings', 'xylim', 'LRAzim', 'step', 'V', 'Data', 'acolor', 'azm', 'ring', 'tth']
None
null
0
0
0
null
0
null
The function (PlotTRImage) defined within the public class called public.The function start at line 5773 and ends at 5834. It contains 51 lines of code and it has a cyclomatic complexity of 11. It takes 5 parameters, represented as [5773.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.FindPeaksBonds
def FindPeaksBonds(XYZ):rFact = data['Drawing'].get('radiusFactor',0.85)#data['Drawing'] could be empty!Bonds = [[] for x in XYZ]for i,xyz in enumerate(XYZ):Dx = XYZ-xyzdist = np.sqrt(np.sum(np.inner(Dx,Amat)**2,axis=1))IndB = ma.nonzero(ma.masked_greater(dist,rFact*2.2))for j in IndB[0]:Bonds[i].append(Dx[j]/2.)Bonds[...
4
11
1
131
0
5,852
5,862
5,852
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.FindPeaksBonds) defined within the public class called public.The function start at line 5852 and ends at 5862. It contains 11 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetCursorStatus
def SetCursorStatus(newxy,contours=False):View = GL.glGetIntegerv(GL.GL_VIEWPORT)Tx,Ty,Tz = drawingData['viewPoint'][0]tx,ty,tz = GLU.gluProject(Tx,Ty,Tz)try:Cx,Cy,Cz = GLU.gluUnProject(newxy[0],View[3]-newxy[1],tz)except: # not sure why this happens, pyOpenGL 3.1.6 bug on MacOS? (3.1.9 OK)G2frame.G2plotNB.status.SetSt...
4
19
2
202
0
5,864
5,882
5,864
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetCursorStatus) defined within the public class called public.The function start at line 5864 and ends at 5882. It contains 19 lines of code and it has a cyclomatic complexity of 4. It takes 2 parameters, represented as [5864.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnKeyBox
def OnKeyBox(event):mode = cb.GetValue()if mode in ['jpeg','bmp','tiff',]:try:import Image as Imexcept ImportError:try:from PIL import Image as Imexcept ImportError:print ("PIL/pillow Image module not present. Cannot save images without this")raise Exception("PIL/pillow Image module not found")projFile = G2frame.GSASpr...
10
44
1
371
0
5,884
5,927
5,884
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnKeyBox) defined within the public class called public.The function start at line 5884 and ends at 5927. It contains 44 lines of code and it has a cyclomatic complexity of 10. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnKey
def OnKey(event): #on key UP!!keyBox = FalseNPkey = Falsetry:keyCode = event.GetKeyCode()if keyCode > 255:keyCode = 0key = chr(keyCode)except AttributeError: #if from OnKeyBox abovekeyBox = Truekey = str(event.key).upper()#indx = drawingData['selectedAtoms']if key in ['C']:drawingData['viewPoint'] = [np.array([.5,.5,.5...
42
174
1
1,626
0
5,929
6,109
5,929
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnKey) defined within the public class called public.The function start at line 5929 and ends at 6109. It contains 174 lines of code and it has a cyclomatic complexity of 42. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnKeyPressed
def OnKeyPressed(event):#On key down for repeating operation - used to change tau...try:keyCode = event.GetKeyCode()if keyCode > 255:keyCode = 0key = chr(keyCode)except AttributeError: #if from OnKeyBox abovekey = str(event.key).upper()if key in ['+','-','=','0']:if generalData['Modulated']:tstep = 1./36 #0.05if key ==...
18
82
1
757
0
6,111
6,192
6,111
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnKeyPressed) defined within the public class called public.The function start at line 6111 and ends at 6192. It contains 82 lines of code and it has a cyclomatic complexity of 18. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.GetTruePosition
def GetTruePosition(xy,Add=False):View = GL.glGetIntegerv(GL.GL_VIEWPORT)Proj = GL.glGetDoublev(GL.GL_PROJECTION_MATRIX)Model = GL.glGetDoublev(GL.GL_MODELVIEW_MATRIX)Zmax = 1.if Add:Indx = GetSelectedAtoms()if not getSelection():#wrong place for doing thisreturnif G2frame.phaseDisplay.GetPageText(getSelection()) == 'M...
16
54
2
444
0
6,194
6,247
6,194
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.GetTruePosition) defined within the public class called public.The function start at line 6194 and ends at 6247. It contains 54 lines of code and it has a cyclomatic complexity of 16. It takes 2 parameters, represented as [6194.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnMouseDown
def OnMouseDown(event):xy = event.GetPosition()if event.ShiftDown():if event.LeftIsDown():GetTruePosition(xy)elif event.RightIsDown():GetTruePosition(xy,True)Draw('Shift atom select')else:drawingData['oldxy'] = list(xy)
4
10
1
58
0
6,249
6,258
6,249
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnMouseDown) defined within the public class called public.The function start at line 6249 and ends at 6258. It contains 10 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnMouseUp
def OnMouseUp(event):'''This is used to initiate a FillCell action after a rigid body has been"dragged" if selected. Flags are used to try to make sure that this is only doneonce, even if multiple mouse up/down actions are made.'''if rbObj and rbObj.get('needsFill') and 'FillUnitCell' in G2frame.testRBObjSizers:if not ...
6
8
1
76
0
6,260
6,271
6,260
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnMouseUp) defined within the public class called public.The function start at line 6260 and ends at 6271. It contains 8 lines of code and it has a cyclomatic complexity of 6. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnMouseMove
def OnMouseMove(event):if event.ShiftDown(): #don't want any inadvertant moves when pickingreturnnewxy = event.GetPosition()if event.Dragging():if event.AltDown() and rbObj:# dragging of a rigid bodyif event.CmdDown(): # Mac middlebutton workaroundSetRBRotationZ(newxy)if rbObj.get('fillMode'): rbObj['needsFill'] = True...
21
48
1
534
0
6,273
6,321
6,273
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnMouseMove) defined within the public class called public.The function start at line 6273 and ends at 6321. It contains 48 lines of code and it has a cyclomatic complexity of 21. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.OnMouseWheel
def OnMouseWheel(event):if event.ShiftDown():returndrawingData['cameraPos'] += event.GetWheelRotation()/24.drawingData['cameraPos'] = max(10,min(500,drawingData['cameraPos']))G2frame.G2plotNB.status.SetStatusText('New camera distance: %.2f'%(drawingData['cameraPos']),1)#drawingData['Zclip'] = min(drawingData['Zclip'],0...
4
18
1
177
0
6,323
6,341
6,323
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.OnMouseWheel) defined within the public class called public.The function start at line 6323 and ends at 6341. It contains 18 lines of code and it has a cyclomatic complexity of 4. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.getSelection
def getSelection():try:return G2frame.phaseDisplay.GetSelection()except:G2frame.G2plotNB.status.SetStatusText('Select this from Phase data window!',1)return 0
2
6
0
30
0
6,343
6,348
6,343
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.getSelection) defined within the public class called public.The function start at line 6343 and ends at 6348. It contains 6 lines of code and it has a cyclomatic complexity of 2. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetViewPointText
def SetViewPointText(VP):page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'Draw Options':G2frame.phaseDisplay.viewPoint.ChangeValue('%.3f %.3f %.3f'%(VP[0],VP[1],VP[2]))
3
5
1
52
0
6,350
6,354
6,350
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetViewPointText) defined within the public class called public.The function start at line 6350 and ends at 6354. It contains 5 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetShowCS
def SetShowCS(CS):page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'Draw Options':G2frame.phaseDisplay.showCS.SetSelection(CS)
3
5
1
35
0
6,356
6,360
6,356
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetShowCS) defined within the public class called public.The function start at line 6356 and ends at 6360. It contains 5 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetRBText
def SetRBText():'''Called w/Locate & Insert Rigid Body to update text in DataWindowwhen the RB orientation/origin is changed via a mouse drag'''page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'RB Models':G2phG.updateAddRBorientText(G2frame,testRBObj,Bmat)if pageCallback:try:pageCallback()excep...
5
10
0
46
0
6,362
6,374
6,362
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetRBText) defined within the public class called public.The function start at line 6362 and ends at 6374. It contains 10 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetViewDirText
def SetViewDirText(VD):page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'Draw Options':G2frame.phaseDisplay.viewDir.ChangeValue('%.3f %.3f %.3f'%(VD[0],VD[1],VD[2]))
3
5
1
52
0
6,376
6,380
6,376
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetViewDirText) defined within the public class called public.The function start at line 6376 and ends at 6380. It contains 5 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetMapPeaksText
def SetMapPeaksText(mapPeaks):data['Map Peaks'] = mapPeakspage = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'Map peaks':G2frame.MapPeaksTable.SetData(data['Map Peaks'])G2frame.MapPeaks.Refresh()
3
7
1
49
0
6,382
6,388
6,382
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetMapPeaksText) defined within the public class called public.The function start at line 6382 and ends at 6388. It contains 7 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetDrawAtomsText
def SetDrawAtomsText(drawAtoms):page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) == 'Draw Atoms':table = G2frame.atomTable.GetData()for i,atom in enumerate(drawAtoms):if generalData['Type'] == 'magnetic':table[i][2:8] = atom[2:8]else:table[i][2:5] = atom[2:5]G2frame.atomTable.SetData(table)G2frame...
5
12
1
101
0
6,390
6,401
6,390
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetDrawAtomsText) defined within the public class called public.The function start at line 6390 and ends at 6401. It contains 12 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.ClearSelectedAtoms
def ClearSelectedAtoms():page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) in ('Draw Atoms','Map peaks','Atoms'):for widget in G2frame.phaseDisplay.GetPage(page).GetChildren():try:widget.ClearSelection()# this is a gridbreakexcept AttributeError:pass
5
11
0
58
0
6,403
6,413
6,403
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.ClearSelectedAtoms) defined within the public class called public.The function start at line 6403 and ends at 6413. It contains 11 lines of code and it has a cyclomatic complexity of 5. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetSelectedAtoms
def SetSelectedAtoms(ind,Add=False):page = getSelection()if page:if G2frame.phaseDisplay.GetPageText(page) in ('Draw Atoms','Map peaks','Atoms'):for widget in G2frame.phaseDisplay.GetPage(page).GetChildren():if hasattr(widget,'GetSelectedRows'): breakelse:returnif G2frame.phaseDisplay.GetPageText(page) == 'Atoms':Id = ...
8
16
2
122
0
6,415
6,430
6,415
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetSelectedAtoms) defined within the public class called public.The function start at line 6415 and ends at 6430. It contains 16 lines of code and it has a cyclomatic complexity of 8. It takes 2 parameters, represented as [6415.0] and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.GetSelectedAtoms
def GetSelectedAtoms():page = getSelection()Ind = []if page:if G2frame.phaseDisplay.GetPageText(page) in ('Draw Atoms','Map peaks','Atoms'):for widget in G2frame.phaseDisplay.GetPage(page).GetChildren():try:Ind = widget.GetSelectedRows()# this is a gridbreakexcept AttributeError:passelif G2frame.phaseDisplay.GetPageTex...
7
16
0
101
0
6,432
6,447
6,432
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.GetSelectedAtoms) defined within the public class called public.The function start at line 6432 and ends at 6447. It contains 16 lines of code and it has a cyclomatic complexity of 7. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetBackground
def SetBackground():R,G,B,A = Page.camera['backColor']GL.glClearColor(R,G,B,A)GL.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT)
1
4
0
42
0
6,449
6,452
6,449
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetBackground) defined within the public class called public.The function start at line 6449 and ends at 6452. It contains 4 lines of code and it has a cyclomatic complexity of 1. The function does not take any parameters and does not return any value..
AdvancedPhotonSource_GSAS-II
public
public
0
0
PlotStructure.SetLights
def SetLights():try:GL.glEnable(GL.GL_DEPTH_TEST)except:if GSASIIpath.GetConfigValue('debug'): print('depth test failed')returnGL.glShadeModel(GL.GL_SMOOTH)GL.glEnable(GL.GL_LIGHTING)GL.glEnable(GL.GL_LIGHT0)GL.glLightModeli(GL.GL_LIGHT_MODEL_TWO_SIDE,0)GL.glLightfv(GL.GL_LIGHT0,GL.GL_AMBIENT,[.2,.2,.2,1])GL.glLightfv(...
3
12
0
113
0
6,454
6,465
6,454
null
[]
None
null
0
0
0
null
0
null
The function (PlotStructure.SetLights) defined within the public class called public.The function start at line 6454 and ends at 6465. It contains 12 lines of code and it has a cyclomatic complexity of 3. The function does not take any parameters and does not return any value..