mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-04 01:02:39 +02:00
[plotting] magnification plot added
This commit is contained in:
parent
4f269aced1
commit
61dbde7a20
1 changed files with 2 additions and 1 deletions
|
|
@ -62,7 +62,7 @@ class MatplotlibPlots(AbstractPlottingLibrary):
|
||||||
if title is not None: ax.set_title(title)
|
if title is not None: ax.set_title(title)
|
||||||
return ax, kwargs
|
return ax, kwargs
|
||||||
|
|
||||||
def show_canvas(self, ax, plots, xlim=None, ylim=None, zlim=None, legend=True, **kwargs):
|
def show_canvas(self, ax, plots, xlim=None, ylim=None, zlim=None, legend=False, **kwargs):
|
||||||
try:
|
try:
|
||||||
ax.autoscale_view()
|
ax.autoscale_view()
|
||||||
ax.set_xlim(xlim)
|
ax.set_xlim(xlim)
|
||||||
|
|
@ -203,6 +203,7 @@ class MatplotlibPlots(AbstractPlottingLibrary):
|
||||||
if not (x.shape == y1.shape == y2.shape == where.shape):
|
if not (x.shape == y1.shape == y2.shape == where.shape):
|
||||||
raise ValueError("Argument dimensions are incompatible")
|
raise ValueError("Argument dimensions are incompatible")
|
||||||
|
|
||||||
|
from functools import reduce
|
||||||
mask = reduce(ma.mask_or, [ma.getmask(a) for a in (x, y1, y2)])
|
mask = reduce(ma.mask_or, [ma.getmask(a) for a in (x, y1, y2)])
|
||||||
if mask is not ma.nomask:
|
if mask is not ma.nomask:
|
||||||
where &= ~mask
|
where &= ~mask
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue