[R] please help with "could not find function "ComBat.mc" "

Yuan Chun Ding ycd|ng @end|ng |rom coh@org
Thu Nov 12 01:39:28 CET 2020


Hi All,

I am very sorry to bother you.

This week, I updated my R from 3.5.3  to 4.0.3, reinstalled all required R packages  and reran the following R code;  then got the following error: could not find function "ComBat.mc".

> #' firstly Removing chip-well batch effects using ComBat from the sva package
> # First we convert from beta-values to M-values
> Mvals1 <- log2(betas.rcp)-log2(1-betas.rcp)
> #' ComBat eBayes adjustment using a known variable of interest (here we use row)
> Mvals.ComBat1 <- ComBat.mc(Mvals1, batch = pData(WB.noob)$Array,nCores = detectCores()-1)
Error in ComBat.mc(Mvals1, batch = pData(WB.noob)$Array, nCores = detectCores() -  : 
  could not find function "ComBat.mc"

I have successfully run the same R code with same data sets several times since 2017.  Google searching tells me that this ComBat.mc function is from an R package "Enmix".  When typing library(Enmix), no error message, so the Enmix library is installed.  Can you tell me why I got this error after updating to new R version? 

Thank you,

Yuan Chun Ding

----------------------------------------------------------------------
------------------------------------------------------------
-SECURITY/CONFIDENTIALITY WARNING-  

This message and any attachments are intended solely for the individual or entity to which they are addressed. This communication may contain information that is privileged, confidential, or exempt from disclosure under applicable law (e.g., personal health information, research data, financial information). Because this e-mail has been sent without encryption, individuals other than the intended recipient may be able to view the information, forward it to others or tamper with the information without the knowledge or consent of the sender. If you are not the intended recipient, or the employee or person responsible for delivering the message to the intended recipient, any dissemination, distribution or copying of the communication is strictly prohibited. If you received the communication in error, please notify the sender immediately by replying to this message and deleting the message and any accompanying files from your system. If, due to the security risks, you do not wish to receive further communications via e-mail, please reply to this message and inform the sender that you do not wish to receive further e-mail from the sender. (LCP301)



More information about the R-help mailing list