Changeset 4804 for trunk/GSASIIplot.py
- Timestamp:
- Feb 7, 2021 8:03:04 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIplot.py
r4803 r4804 1941 1941 elif event.key == 'f' and not G2frame.SinglePlot: 1942 1942 choices = G2gd.GetGPXtreeDataNames(G2frame,plotType) 1943 dlg = G2G.G2MultiChoiceDialog(G2frame,'Select dataset to plot', 1943 dlg = G2G.G2MultiChoiceDialog(G2frame, 1944 'Select dataset(s) to plot\n(select all or none to reset)', 1944 1945 'Multidata plot selection',choices) 1945 1946 if dlg.ShowModal() == wx.ID_OK: … … 3236 3237 YB = Y 3237 3238 ZB = Z+B 3238 Plot.set_yscale("log",nonposy='mask') 3239 try: 3240 Plot.set_yscale("log",nonpositive='mask') # >=3.3 3241 except: 3242 Plot.set_yscale("log",nonposy='mask') 3239 3243 if np.any(W>0.): 3240 3244 lims = [np.min(np.trim_zeros(W))/2.,np.max(Y)*2.] … … 3261 3265 if Page.plotStyle['logPlot']: 3262 3266 if 'PWDR' in plottype: 3263 Plot.set_yscale("log",nonposy='mask') 3267 try: 3268 Plot.set_yscale("log",nonpositive='mask') # >=3.3 3269 except: 3270 Plot.set_yscale("log",nonposy='mask') 3264 3271 Plot.plot(X,Y,marker=pP,color=colors[0], 3265 3272 picker=True,pickradius=3.,clip_on=Clip_on,label=incCptn('obs')) … … 3269 3276 Plot.plot(X,W,colors[2],picker=False,label=incCptn('bkg')) #background 3270 3277 elif plottype in ['SASD','REFD']: 3271 Plot.set_xscale("log",nonposx='mask') 3272 Plot.set_yscale("log",nonposy='mask') 3278 try: 3279 Plot.set_xscale("log",nonpositive='mask') # >=3.3 3280 Plot.set_yscale("log",nonpositive='mask') 3281 except: 3282 Plot.set_xscale("log",nonposx='mask') 3283 Plot.set_yscale("log",nonposy='mask') 3273 3284 if G2frame.ErrorBars: 3274 3285 if Page.plotStyle['sqPlot']: … … 3346 3357 if Page.plotStyle['logPlot']: 3347 3358 if 'PWDR' in plottype: 3348 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), 3349 picker=False,nonposy='mask') 3359 try: 3360 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), # >=3.3 3361 picker=False,nonpositive='mask') 3362 except: 3363 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), 3364 picker=False,nonposy='mask') 3350 3365 elif plottype in ['SASD','REFD']: 3351 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), 3352 picker=False,nonposy='mask') 3366 try: 3367 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), 3368 picker=False,nonpositive='mask') 3369 except: 3370 Plot.semilogy(X,Y,color=mcolors.cmap(icolor), 3371 picker=False,nonposy='mask') 3353 3372 else: 3354 3373 if 'PWDR' in plottype: 3355 3374 Plot.plot(X,Y,color=mcolors.cmap(icolor),picker=False) 3356 3375 elif plottype in ['SASD','REFD']: 3357 Plot.loglog(X,Y,mcolors.cmap(icolor), 3358 picker=False,nonposy='mask') 3376 try: 3377 Plot.loglog(X,Y,mcolors.cmap(icolor), 3378 picker=False,nonpositive='mask') 3379 except: 3380 Plot.loglog(X,Y,mcolors.cmap(icolor), 3381 picker=False,nonposy='mask') 3359 3382 Plot.set_ylim(bottom=np.min(np.trim_zeros(Y))/2.,top=np.max(Y)*2.) 3360 3383 … … 4552 4575 elif event.key == 'f' and not G2frame.SinglePlot: 4553 4576 choices = G2gd.GetGPXtreeDataNames(G2frame,'PDF ') 4554 dlg = G2G.G2MultiChoiceDialog(G2frame,'Select dataset to plot', 4577 dlg = G2G.G2MultiChoiceDialog(G2frame, 4578 'Select PDF(s) to plot\n(select all or none to reset)', 4555 4579 'Multidata plot selection',choices) 4556 4580 if dlg.ShowModal() == wx.ID_OK: 4557 4581 G2frame.PDFselections = [] 4558 4582 select = dlg.GetSelections() 4559 if select :4583 if select and len(select) != len(choices): 4560 4584 for Id in select: 4561 4585 G2frame.PDFselections.append(choices[Id])
Note: See TracChangeset
for help on using the changeset viewer.