Skip to content

Commit

Permalink
Merge pull request #1001 from ericpre/add_kwargs_to_plot_in_Parameter…
Browse files Browse the repository at this point in the history
…_class

add **kwargs to the plot method of Parameter instance
  • Loading branch information
to266 committed May 19, 2016
2 parents c2a99da + 96a58ee commit ddfc216
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions hyperspy/component.py
Original file line number Diff line number Diff line change
Expand Up @@ -514,8 +514,23 @@ def as_signal(self, field='values'):
navigate=True)
return s

def plot(self):
self.as_signal().plot()
def plot(self, **kwargs):
"""Plot parameter signal.
Parameters
----------
**kwargs
Any extra keyword arguments are passed to the signal plot.
Example
-------
>>> parameter.plot()
Set the minimum and maximum displayed values
>>> parameter.plot(vmin=0, vmax=1)
"""
self.as_signal().plot(**kwargs)

def export(self, folder=None, name=None, format=None,
save_std=False):
Expand Down

0 comments on commit ddfc216

Please sign in to comment.