mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-08 03:22:38 +02:00
plotting \o/
This commit is contained in:
parent
a98334e009
commit
0062a5b16f
2 changed files with 2 additions and 2 deletions
|
|
@ -73,7 +73,7 @@ class Kern(Parameterized):
|
||||||
See GPy.plotting.matplot_dep.plot
|
See GPy.plotting.matplot_dep.plot
|
||||||
"""
|
"""
|
||||||
assert "matplotlib" in sys.modules, "matplotlib package has not been imported."
|
assert "matplotlib" in sys.modules, "matplotlib package has not been imported."
|
||||||
from ..plotting.matplot_dep import kernel_plots
|
from ...plotting.matplot_dep import kernel_plots
|
||||||
kernel_plots.plot(self,*args)
|
kernel_plots.plot(self,*args)
|
||||||
|
|
||||||
def plot_ARD(self, *args, **kw):
|
def plot_ARD(self, *args, **kw):
|
||||||
|
|
|
||||||
|
|
@ -106,7 +106,7 @@ def plot(kernel, x=None, plot_limits=None, which_parts='all', resolution=None, *
|
||||||
raise ValueError, "Bad limits for plotting"
|
raise ValueError, "Bad limits for plotting"
|
||||||
|
|
||||||
Xnew = np.linspace(xmin, xmax, resolution or 201)[:, None]
|
Xnew = np.linspace(xmin, xmax, resolution or 201)[:, None]
|
||||||
Kx = kernel.K(Xnew, x, which_parts)
|
Kx = kernel.K(Xnew, x)
|
||||||
pb.plot(Xnew, Kx, *args, **kwargs)
|
pb.plot(Xnew, Kx, *args, **kwargs)
|
||||||
pb.xlim(xmin, xmax)
|
pb.xlim(xmin, xmax)
|
||||||
pb.xlabel("x")
|
pb.xlabel("x")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue