possible error in medmod
Posted: Wed Aug 18, 2021 1:27 pm
dear jamovi makers,
first, we would like to make you a compliment. jamovi is great!
but we may have encountered an error on medmod.
generate a data set wirh the followin r-code
rm(list = ls(all = TRUE)) # clears workspace
require(MASS)
n <- 1000 # set sample size
x <- mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
z <- mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
y <- 2*x + 3*z + 4*x*z + 1 + mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
xyz <-data.frame(x, y, z)
lm(y ~ x*z, xyz)
save(xyz, file="d:/xyz.RData")
if you run now the analysis with medmod, you will get different results than the lm comand provided (additionally, no constant is displayed. if you analyse via jamovi with linear regression, resuls are correct.
best, camila and jochen
first, we would like to make you a compliment. jamovi is great!
but we may have encountered an error on medmod.
generate a data set wirh the followin r-code
rm(list = ls(all = TRUE)) # clears workspace
require(MASS)
n <- 1000 # set sample size
x <- mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
z <- mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
y <- 2*x + 3*z + 4*x*z + 1 + mvrnorm(n = n, 0, 1, tol = 1e-6, empirical = FALSE, EISPACK = FALSE)
xyz <-data.frame(x, y, z)
lm(y ~ x*z, xyz)
save(xyz, file="d:/xyz.RData")
if you run now the analysis with medmod, you will get different results than the lm comand provided (additionally, no constant is displayed. if you analyse via jamovi with linear regression, resuls are correct.
best, camila and jochen