Skip to content
Back to formatted view

Raw Message

Message-ID: <F986CFE6-3704-4D2E-B4FB-67773B756AD5@comcast.net>
Date: 2011-12-15T14:56:31Z
From: David Winsemius
Subject: modify the name of axis of an R function
In-Reply-To: <1323931998628-4198804.post@n4.nabble.com>

On Dec 15, 2011, at 1:53 AM, plocq wrote:

> Hi,
>
> I use the function fpot of packages evd. If I call the fit that I  
> obtain
> "fit", I want to modify the name of the axis and the main title that  
> is
> produced by plot(fit1).

Usually this would be accomplished with

plot(fit, main="main title", xlab="X-axis lable", ylab="y-axis label")

> To do this, I want to create a new function where I
> would have the names modified.

Seems unlikely that this would be needed.

> The problem is that I can't find the function
> that produce these plots... I tried to see in plot.uvevd but it  
> doesn't
> seems to be the good one. Can anybody help me?
> Many thanks!

The way to address this, if you are committed to this path, is to  
first determine the class of the fit-object and then to look for a  
plot method with methods(plot). If you see an S3 method you can call  
up the code with:

evd:::plot.fit-class  # when "fit-class" is the value you got with  
class(fit)

If it's an S4 method, then it's much more convoluted, and over time  
I've learned not to try.

-- 

David Winsemius, MD
West Hartford, CT