chanw0 / MTA

R package
1 stars 0 forks source link

Example errors? #1

Open BinhongLiu opened 4 years ago

BinhongLiu commented 4 years ago

Hi Dr Wang, MTA is really a nice R package for longitudinal microbiome data analysis. While I found there were some errors with the example data in the MTA-manual.pdf. First, when generating two groups: for(t in 1:T){ betaT=rep(0,P) effect.size1=c(-1,2, -1)min(beta0[causal.ind])sin(t) betaT[causal.ind]=effect.size1 group2[, ,t] = rdirichlet(N,(beta0+betaT)) } Warning messages: 1: In rgamma(n, shape = alpha[i]) : produced NA 2: In rgamma(n, shape = alpha[i]) : produced NA 3: In rgamma(n, shape = alpha[i]) : produced NA

second, when performing the MTA function: MTA(Y1=group1) Error in MTA(Y1 = group1) : no "MTA" function

could you help me with these errors, please? Thanks! hongbin liu

chanw0 commented 4 years ago

Hi Hongbin,

Thank you for using our package!

  1. For the data generation, please make sure that parameter beta0 and (beta0+betaT) are positive since the model used for data generation is the Dirichlet distribution, in which all parameters should be positive.
  2. For the error "no MTA function", please make sure that you had installed MTA package correctly. You can run the script "library(MTA)" to confirm it. If you don't install it, you can run the script as below:

library(devtools) install_github("chanw0/MTA").

If you have any additional questions, feel free to contact me. Thank you again for using our package. Good luck!

Best, Chan