title: How to prevent "The following object is masked from ‘package:...’:..." trouble/warning totally when loading a package?
body: <p>When I load a package I created, I get the following warning:</p>
  
  <blockquote>
    <p>"The following object is masked from ‘package:utils’:combn"</p>
  </blockquote>
  
  <p>even though I used combinat::combn in function definitions in .R files of "R" folder in R's working directory.</p>
  
  <p>Isn't there any way to get rid of "...object is masked from..." warning?
  (I don't want to mask combn at all; See Gregor's post below.)</p>
  
  <p>I added "combinat::" prefix in my definitions of functions in my package wherever I wanna use the combn of combinat in order not to get the above warning (mixing of combinat::combn with utils::combn).</p>
  
  <p><strong>gctemplate</strong> is a function of the package causfinder (I removed "combinat::" for those who want to grasp the function; when I pump "combinat::" prefix wherever I see combn in the function gctemplate, I still received the above warning):  </p>
  
  <pre><code>#' gctemplate
  #'
  #' Granger causality template for a given system in the desired pattern.
  #'
  #' Assume a system in which its Granger causality relations among its variables will be searched is given. For the variables of this system (with nvars variables), some varibles may cause (causers, like independents) some others (those that are caused by causers, like dependents) conditional on some others in the system. The function gctemplate has three arguements to list all the possible causation pattern in which Granger causality will be searched. As is known, dependent and independent variables are not specified in the beginning of a Granger analysis, the analysis reveals them.
  #'
  #' @param nvars integer. The number of all the variables in a given system.
  #' @param ncausers integer. The selected number of causer (independent-like) variables
  #' @param ndependents integer. The selected number of variables that are caused by the causers, number of dependent-like variables
  #' @return granger causality template
  #' @author Erdogan Cevher erdogancevher@@gmail.com
  #' @seealso \code{\link{conditionalGb}}
  #' @examples
  #' ## List all G-causalities in a VAR system of 5 variables that will be searched in the pattern of 1 
  #' ## causer (like-independent) variable and 2 like-dependents conditional on 5-(1+2)=2 of the remaining 
  #' ## variable(s) in the system. Varibles are assigned to numbers 1 to nvars. 
  #' ## "1 2 5 3 4" in the rsulting line of gctemplate is to indicate the 
  #' ## (conditonal, partial, etc.) G-causality from variable 1 to varibles 2 and 5 
  #' ## conditonal on variables 3 and 4.
  #' # gctemplate(5,1,2)
  #' ## The number of all G-causalities to be searched in the above pattern.
  #' #dim(gctemplate(5,1,2))[[1]]
  #' @importFrom combinat combn
  #' @export
  gctemplate &lt;- function(nvars, ncausers, ndependents){  
  independents &lt;- combn(nvars, ncausers)  
  patinajnumber &lt;-  dim(combn(nvars - ncausers, ndependents))[[2]]  
  independentspatinajednumber &lt;- dim(combn(nvars, ncausers))[[2]]*patinajnumber   
  dependents &lt;- matrix(, nrow = dim(combn(nvars, ncausers))[[2]]*patinajnumber, ncol = ndependents)  
  for (i in as.integer(1:dim(combn(nvars, ncausers))[[2]])){     
  dependents[(patinajnumber*(i-1)+1):(patinajnumber*i),] &lt;- t(combn(setdiff(seq(1:nvars), independents[,i]), ndependents))  
  }  
  independentspatinajed &lt;- matrix(, nrow = dim(combn(nvars, ncausers))[[2]]*patinajnumber, ncol = ncausers)  
  for (i in as.integer(1:dim(combn(nvars, ncausers))[[2]])){     
  for (j in as.integer(1:patinajnumber)){     
  independentspatinajed[(i-1)*patinajnumber+j,] &lt;- independents[,i]    
  }}  
  independentsdependents &lt;- cbind(independentspatinajed, dependents)  
  others &lt;- matrix(, nrow = dim(combn(nvars, ncausers))[[2]]*patinajnumber, ncol = nvars - ncausers - ndependents)   
  for (i in as.integer(1:((dim(combn(nvars, ncausers))[[2]])*patinajnumber))){    
  others[i, ]  &lt;- setdiff(seq(1:nvars), independentsdependents[i,])   
  }  
  causalitiestemplate &lt;- cbind(independentsdependents, others)  
  causalitiestemplate  
  }  
  </code></pre>
  
  <p>The following is the content of <strong>DESCRIPTION</strong> FILE:  </p>
  
  <pre><code>Package: causfinder  
  Type: Package  
  Title: A visual analyser for pairwise and multivariate conditional and partial  
  Granger causalities. For a list of documented functions, use library(help =  
  "causfinder")  
  Version: 2.0  
  Date: 2014-10-05  
  Author: Erdogan CEVHER &lt;erdogancevher@gmail.com&gt;  
  Maintainer: Erdogan CEVHER &lt;erdogancevher@gmail.com&gt;  
  Description: Given a system of finite number of variables with their data in a  
  matrix, the functions in the causfinder package analyze the pairwise and  
  multivariate conditional and partial Granger causalities in a systematic  
  and overall approach. By "overall approach" we mean that all the  
  G-causalities among the variables in a certain desired pattern are  
  calculated (the user then can retrieve his/her G-causality in interest as  
  one element of the pattern). This pattern may correspond to pairwise or  
  multivariate Granger causalities. Some of the functions in the package use  
  bootstrapping whereas some others not. The analysis of the Granger  
  causalities are performed via various ways; i.e., presenting the F  
  statistics, p values, lower bounds and upper bounds of the bootstrapping  
  values etc., and via presenting various plots and grid matrixes. For a list  
  of documented functions, use library(help = "causfinder")  
  Depends:  
      R (&gt;= 3.0.2)  
  Imports:  
      np(&gt;= 0.50-1),RColorBrewer(&gt;= 1.0-5),grid,scales(&gt;= 0.2.4),boot(&gt;= 1.3-11),calibrate(&gt;= 1.7.2),combinat(&gt;= 0.0-8),corpcor(&gt;= 1.6.6)  
  License: GPL (&gt;= 3)  
  LazyLoad: yes  
  LazyData: yes  
  URL: https://github.com/erdogancevher/causfinder  
  </code></pre>
  
  <p><strong>NOTE:</strong> Renaming the function combn of the combinat package as combnnn and putting its content (its .R file etc.) to my package R folder; and applying rexoginzation procedure may not result in the above warning. What I tried to obtain is just a systematic way to prevent the warning, not the very tricky/long way I described in this note.</p>