Name conflict between Epi and ROC packages

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Name conflict between Epi and ROC packages

Tuszynski, Jaroslaw W.
The name conflicts in Epi and ROC packages (2 'ROC' functions are the
problem) cause the following code
to work once, but not twice:

  library(MASS); data(cats);
  x = cats[,2]
  y = ifelse(cats[,1]=='F',0,1)
  library(Epi); ROC(x,y,grid=0)$AUC
  library(ROC); AUC(rocdemo.sca(y, x, dxrule.sca))    

What is the standard way of resolving name conflicts? Ask maintainers to
resolve it or rename the younger function, use namespaces somehow, or
something else?

My machine is WinXP, R-2.2.0, ROC and Epi packages are the latest versions.

Jarek Tuszynski

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Name conflict between Epi and ROC packages

Vincent Carey 525-2265
we can use name spaces.  i will try to put one in for ROC ASAP.
best regards

---
Vince Carey, PhD
Assoc. Prof Med (Biostatistics)
Harvard Medical School
Channing Laboratory - ph 6175252265 fa 6177311541
181 Longwood Ave Boston MA 02115 USA
[hidden email]

On Thu, 15 Dec 2005, Tuszynski, Jaroslaw W. wrote:

> The name conflicts in Epi and ROC packages (2 'ROC' functions are the
> problem) cause the following code
> to work once, but not twice:
>
>   library(MASS); data(cats);
>   x = cats[,2]
>   y = ifelse(cats[,1]=='F',0,1)
>   library(Epi); ROC(x,y,grid=0)$AUC
>   library(ROC); AUC(rocdemo.sca(y, x, dxrule.sca))
>
> What is the standard way of resolving name conflicts? Ask maintainers to
> resolve it or rename the younger function, use namespaces somehow, or
> something else?
>
> My machine is WinXP, R-2.2.0, ROC and Epi packages are the latest versions.
>
> Jarek Tuszynski
>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Name conflict between Epi and ROC packages

Seth Falcon-2
In reply to this post by Tuszynski, Jaroslaw W.
On 15 Dec 2005, [hidden email] wrote:

> The name conflicts in Epi and ROC packages (2 'ROC' functions are
> the problem) cause the following code to work once, but not twice:
>
> library(MASS); data(cats);
> x = cats[,2]
> y = ifelse(cats[,1]=='F',0,1)
> library(Epi); ROC(x,y,grid=0)$AUC
> library(ROC); AUC(rocdemo.sca(y, x, dxrule.sca))    
>
> What is the standard way of resolving name conflicts? Ask
> maintainers to resolve it or rename the younger function, use
> namespaces somehow, or something else?

This may not help you now, but in the next Bioconductor release, the
ROC package will have a name space.  Then you can use ROC::AUC,
ROC::ROC to get the functions you want.

+ seth

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Name conflict between Epi and ROC packages

Vincent Carey 525-2265
In reply to this post by Tuszynski, Jaroslaw W.
apparently there is already a namespace for ROC.  so
whenever you need disambiguation and want to select the
function defined in ROC, use ROC::f
where "f" names a function in ROC package, and "f" is
also used in another package on the searchlist.

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Loading...