Mediate function - bug?

Hi all, I am using the mediate function for multilevel analysis but I keep running into the error: "unused arguments (treat = "PS", sims = 1000, conf.level = 0.95)"
I also tried to run the code that is posted in the manual itself with the provided data "framework" on mediate and it gives the same error!! Does anyone have any guidance?

This is my code: medmodel <- mediate(model1.idps.covs, model2.mod.covs, treat="PS", mediator="iDealcm", boot=TRUE, sims=1000, conf.level = 0.95)

Is it possible you have another function named mediate masking your intended function. Try running

medmodel <- mediation::mediate(model1.idps.covs, model2.mod.covs, treat="PS", 
        mediator="iDealcm", boot=TRUE, sims=1000, conf.level = 0.95)

There were some issues earlier in my code and one was that I had too many packages loaded so there was some masking going on! Thank you!!

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.