Re: [R] Mediation analysis takes up all RAM, then all swap, and then RStudio/terminal suddenly closes

2021-06-23 Thread Phillips Rogfield
Hello Bert, thank you for your kinds answer. No I didn't contact the maintainer of the package first, that's my fault :) I have come to the conclusion that the problem is that I don't have enough resources on my PC (RAM) for the task at hand. I have tried to run it on a remote VM with more RAM

Re: [R] Mediation analysis takes up all RAM, then all swap, and then RStudio/terminal suddenly closes

2021-06-22 Thread Bert Gunter
Please read and follow the posting guide, linked below, which says: "For questions about functions in standard packages distributed with R (see the FAQ Add-on packages in R ), ask questions on R-help. If the question relates to a

[R] Mediation analysis takes up all RAM, then all swap, and then RStudio/terminal suddenly closes

2021-06-22 Thread Philips Roger
I am using the mediation package to run a mediation analysis. But when I call the `mediate` function, R eats up all RAM, then it eats up all swap, and then RStudio suddenly closes. The same happens if I call `Rscript` from the terminal, and the t

[R] mediation analysis in R using the method described by Lange T., et al. in the paper "A simple unified approach for estimating natural direct and direct effects

2014-12-21 Thread Ruzan Udumyan
Dear All, I need to do a mediation analysis with survival data (using Cox model). - The independent variable is categorical (with 3 levels, coded as 1, 2, 3). - Mediator variable is a 1-10 score variable (derived from a continuous variable). I must confess, I am a Stata user. Howeve

[R] Mediation using 'mediate' in R with an interaction

2014-05-09 Thread Lauren Howe
Hi everyone, I have a question about mediation when there is an interaction between 2 categorical variables, one with two levels and one with three levels. Using the ‘mediation’ package by Tingley and colleagues in R, I’m trying to conduct a bootstrapped mediation analysis for an interacti

[R] Mediation with multilevel data - Random slopes or not?

2014-04-18 Thread Berna Arslan Uzundağ
Hi, I have been using the mediation package in R to test for mediation in multilevel data. My data is as follows: X: continuous, M: binary, and Y: binary (Y:outcome, M: mediator) I'm testing a 1-1-1 mediation. I get different results when I use random slopes in the equations and when I don't. My

Re: [R] Mediation analysis

2012-07-31 Thread Michael Friendly
Subset your data first and/or use the data= and subset= arguments to lm() so the same data is used in all models. On 7/31/2012 2:14 PM, jawortman wrote: Hello all, I apologize for the simplistic question, but I have been having some trouble learning how to do mediation analysis in R. Ideally,

[R] Mediation analysis

2012-07-31 Thread jawortman
Hello all, I apologize for the simplistic question, but I have been having some trouble learning how to do mediation analysis in R. Ideally, I would like to use Preacher's Bootstrapping test for mediation (Preacher & Hayes, 2004). I have attempted to use the mediate package to set this up, using c

[R] Mediation with censored outcome

2011-07-07 Thread Niklaus Kuehnis
Hi all, Is it possible to test mediation effects with a censored outcome variable using the 'mediation' package? While on p. 1f. of Imai, Keele, Tingley and Yamamoto (2011) the tobit model is mentioned for use with 'mediate', Table 1 (p. 8) shows that tobit via vglm cannot be used to estimat

Re: [R] mediation

2011-05-19 Thread Андрей Гончар
You can see the whole function by printing its name in console. Example: > plot function (x, y, ...) { if (is.function(x) && is.null(attr(x, "class"))) { if (missing(y)) y <- NULL hasylab <- function(...) !all(is.na(pmatch(names(list(...)), "ylab")))

[R] mediation

2011-05-19 Thread Mervi Virtanen
Hi! I try to find out how bootstrap mediation work! How I coud see the whole function or algorithm? (rather whole bootstrap). t.Mete __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting gui