Dear Mohammad Tanvir Ahamed,

Re:

> Hi!, 
> 
> Lets I have a function form a package. 
> The function is,  as an example, 
> 
> myplot <- function(x,y) { plot(x,y) }
> 
> 
> Now I can use the function according to function's defined argument. 
> 
> x<- sort(runif(200))
> y<- 1:200
> myplot(x,y)
> 
> Now I want to input extra argument or override default value of plot inside 
> the function myplot. 
> 
> If I use  myplot (x,y, col = "red", cex = 0.1 )  it does not work . I clearly 
> understand , why it does not work . 
> But in this situation how can i solve the problem ? 
> 



That's where the three-dot argument is for.

See "Introduction to R", paragraph 10.4 The ‘…’ argument.

Succes and
best regards,

Frank
---


Franklin Bretschneider
Dept of Biology
Utrecht University
brets...@xs4all.nl

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to