Hi Laura,
As far as I am concerned, you account for multiple effects sizes from the same
study by setting up and fitting an appropriate model, not by fiddling with the
weights. Several examples are described here:
Very difficult to diagnose what is going on without actually seeing the data.
But as I said on CV: Depending on the data, the variance components may not be
estimated precisely, so negative values for those kinds of pseudo-R^2
statistics are quite possible. In fact, if a particular moderator is
You are not conducting a proper test of the moderator. When you use 'mods =
~factor(sample_data$Participants) - 1', the model does not include an intercept
term but dummy variables corresponding to all levels of the moderator. The
omnibus test you are getting therefore tests the null hypothesis
The code in your mail in a mangled mess, since you posted in HTML. Please
configure your email client to send emails in plain text.
Could you explain what exactly you mean by "Currently it is using a mixed
effects model. Is it possible to change the code so a random effects model is
used?"
Sort of an obvious approach, but after every upgrade (regardless if it is
major/minor), I just delete my entire personal library and reinstall everything
from scratch. For this, I have a script that includes just a bunch of
install.packages() calls. Like:
install.packages(c("lme4", "glmmML",
You could use an offset term. An example:
n <- 100
x1 <- rnorm(n)
x2 <- rnorm(n)
x3 <- rnorm(n)
y <- 0 + .2 * x1 - .5 * x2 + .3 * x3 + rnorm(n)
res1 <- lm(y ~ x1 + x2)
summary(res1)
res2 <- lm(y ~ 1 + offset(coef(res1)[2] * x1 + coef(res1)[3] * x2))
summary(res2) ### identical intercept as in
I would suggest to post this to the (recently created) R-sig-meta-analysis
mailing list. See:
https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
Best,
Wolfgang
>-Original Message-
>From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Naike Wang
>Sent: Monday, June 26,
Hi All,
It seems to me that xyTable() gets thrown off by NAs:
x <- c(1, 1, 2, 2, 2, 3)
y <- c(1, 2, 1, 3, NA, 3)
table(x, y, useNA="always")
xyTable(x, y)
Is this intended behavior?
Best,
Wolfgang
__
R-help@r-project.org mailing list -- To
Hi All,
I have one vector that I want to combine with another vector and that other
vector should be the same for every row in the combined matrix. This obviously
does not work:
vec <- c(2,4,3)
cbind(1:5, vec)
This does, but requires me to specify the correct value for 'n' in replicate():
This aside, there is the R-sig-meta-analysis mailing list where this probably
belongs:
https://stat.ethz.ch/mailman/listinfo/r-sig-meta-analysis
Best,
Wolfgang
>-Original Message-
>From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Bert
>Gunter
>Sent: Thursday, 15
--Original Message-
>From: Jeff Newmiller [mailto:jdnew...@dcn.davis.ca.us]
>Sent: Tuesday, 03 July, 2018 17:48
>To: r-help@r-project.org; Viechtbauer, Wolfgang (SP); r-help@r-
>project.org
>Subject: Re: [R] Combine by columns a vector with another vector that is
>consta
Dear Petr,
Sorry, no experience with the FTH, but related to this, has anybody gotten R to
interface nicely with the Retro Encabulator, providing live read outs of the
synchronizing cardinal grammeters?
(my apologies, I just couldn't resist)
Best,
Wolfgang
>-Original Message-
>From:
Dear Greg,
I am not sure if I understand your question. If you are asking how to do this
in R, then one could use the metafor or meta package for this. The specificity
and sensitivity values are proportions, so one would usually meta-analyze them
after a logit transformation. But all of the
Hi All,
I am trying to create a vector of expressions, where the elements in the
expressions are contained in other vectors (i.e., they should be substituted).
I made some attempts with substitute() and bquote(), but couldn't get this to
work. My solution so far is:
base <- 1:5
expo <-
, 2019 14:42
To: Viechtbauer, Wolfgang (SP)
Cc: r-help mailing list
Subject: Re: [R] Substitution in expressions
Er, I'm confused.
You post some code, the code does something. In which sense is this not what
you want?
This is slightly more direct:
> mapply(function(x,y) as.expression(bquote(
Ok, thanks. Happy to stick with mapply() then.
Best,
Wolfgang
-Original Message-
From: peter dalgaard [mailto:pda...@gmail.com]
Sent: Tuesday, 26 March, 2019 15:40
To: Viechtbauer, Wolfgang (SP)
Cc: r-help mailing list
Subject: Re: [R] Substitution in expressions
I think mapply
Hi Bert,
I am indeed creating a mathematical expression, but ?plotmath doesn't cover how
to do such a vectorized substitution.
Best,
Wolfgang
-Original Message-
From: Bert Gunter [mailto:bgunter.4...@gmail.com]
Sent: Tuesday, 26 March, 2019 15:52
To: Viechtbauer, Wolfgang (SP)
Cc: r
Gunter [mailto:bgunter.4...@gmail.com]
Sent: Tuesday, 26 March, 2019 17:43
To: Viechtbauer, Wolfgang (SP)
Cc: r-help mailing list
Subject: Re: [R] Substitution in expressions
Perhaps something like this (apologies if beating a dead horse):
plot(NA,NA, xlim = c(-1,5),ylim = c(-1,5), xlab = "&q
The second argument (called 'vi') in rma() is for the variances. If you have
SEs, then use the 'sei' argument:
res <- rma(HR, sei=SE, data=a)
Best,
Wolfgang
-Original Message-
From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of greg holly
Sent: Monday, 25 February, 2019
hod="REML", slab=paste(a$study), digits=3)
Best,
Wolfgang
-Original Message-
From: greg holly [mailto:mak.hho...@gmail.com]
Sent: Monday, 25 February, 2019 21:20
To: Viechtbauer, Wolfgang (SP)
Subject: Re: [R] differences between meat and metafor packages
Hi
Dear Heather,
You can do this with clogit() from the 'survival' package, using strata(). See:
http://www.metafor-project.org/doku.php/tips:clogit_paired_binary_data
You can also use lme4::glmer(), glmmML::glmmML(), or metafor::rma.glmm() for
that. [1]
[1] Rerunning this example, I noticed a
Dear John,
The linearHypothesis() function from the 'car' package does this.
>From the help file: "The value of the linear hypothesis and its covariance
>matrix are returned respectively as "value" and "vcov" attributes of the
>object (but not printed)." For a single linear combination, vcov
Dear All,
I would like to announce the release of the 'mathjaxr' package:
https://cran.r-project.org/package=mathjaxr
The package provides MathJax and a handful of macros to enable its use within
Rd files for rendering equations in the HTML help files.
Package authors wanting to make use of
Dear Kobby,
Please post the output of sessionInfo() and class(result.md).
Best,
Wolfgang
>-Original Message-
>From: K Amoatwi [mailto:amoatwi...@gmail.com]
>Sent: Monday, 22 June, 2020 22:30
>To: Viechtbauer, Wolfgang (SP)
>Cc: r-help@r-project.org
>Subject: Re:
il.com]
>Sent: Tuesday, 23 June, 2020 16:37
>To: Viechtbauer, Wolfgang (SP)
>Cc: r-help@r-project.org
>Subject: Re: [R] Error message in meta-analysis package Metafor-weights =""
>
>Dear Wolfgang,
>I have posted the requested information you askedĀ for.
>
>&g
Dear Amoatwi,
This way of using the escalc() function has been deprecated. It might be added
back once there is actually any benefit from having this functionality, but for
years it just meant that I had to maintain two different ways of doing the
exact same thing without any additional
Dear Sigbert,
The mathjaxr package provides this:
https://cran.r-project.org/package=mathjaxr
https://github.com/wviechtb/mathjaxr
Best,
Wolfgang
>-Original Message-
>From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Sigbert
>Klinke
>Sent: Tuesday, 12 January, 2021 9:14
Hi all,
On my system (Xubuntu 20.04), using par(family="mono") is not rendered
correctly. The same issue was raised here:
https://stackoverflow.com/questions/64207220/rendering-plot-in-r-with-mono-spaced-family-font-does-not-display-characters-any
Using par(family="monospace") does work:
R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Viechtbauer,
>Wolfgang (SP)
>Sent: Wednesday, 20 January, 2021 9:44
>To: Paul Murrell; r-help@r-project.org
>Subject: Re: [R] Monospaced font not shown correctly (Xubuntu 20.04)
>
>Dear Paul,
>
>Thanks for the helpful repl
/DejaVuSansMono.ttf
Substitute your favorite (ttf/otf) monospaced font above.
Best,
Wolfgang
>-Original Message-
>From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Viechtbauer,
>Wolfgang (SP)
>Sent: Wednesday, 20 January, 2021 10:10
>To: Paul Mu
-*-*-%d-*-*-*-*-*-*-*")
X11(family="mono")
plot(1)
Best,
Wolfgang
>-Original Message-
>From: Paul Murrell [mailto:p...@stat.auckland.ac.nz]
>Sent: Wednesday, 20 January, 2021 0:37
>To: Viechtbauer, Wolfgang (SP); r-help@r-project.org
>Subject: Re: [R] M
Dear Jiefei,
This behavior is documented. From help(wilcox.test):
"By default (if exact is not specified), an exact p-value is computed if the
samples contain less than 50 finite values and there are no ties. Otherwise, a
normal approximation is used."
Best,
Wolfgang
>-Original
Dear Usmle Ck,
This is what the 'slab' argument is for (for adding 'study labels'). For an
example, see:
https://www.metafor-project.org/doku.php/plots:forest_plot
Best,
Wolfgang
>-Original Message-
>From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Usmle Ck
>Sent:
message:
In wilcox.test.default(c(1, 3, 2, 2, 4), exact = TRUE) :
cannot compute exact p-value with ties
Best,
Wolfgang
>-Original Message-
>From: Jiefei Wang [mailto:szwj...@gmail.com]
>Sent: Friday, 19 March, 2021 16:32
>To: Viechtbauer, Wolfgang (SP)
>Cc: r-help
>Subject:
>-Original Message-
>From: Duncan Murdoch [mailto:murdoch.dun...@gmail.com]
>Sent: Monday, 12 April, 2021 1:58
>To: Viechtbauer, Wolfgang (SP); R-help
>Subject: Re: [R] evil attributes
>
>On 11/04/2021 2:46 p.m., Viechtbauer, Wolfgang (SP) wrote:
>> The is.vector
Dear Roger,
The problem is this. qss() looks like this:
if (is.matrix(x)) {
[...]
}
if (is.vector(x)) {
[...]
}
qss
Now let's check these if() statements:
is.vector(B$x) # TRUE
is.vector(D$x) # FALSE
is.matrix(B$x) # FALSE
is.matrix(D$x) # FALSE
is.vector(D$x) being FALSE may be
The is.vector() thing has also bitten me in the behind on a few occasions. When
I want to check if something is a vector, allow for it to possibly have some
additional attributes (besides names) that would make is.vector() evaluate to
FALSE, but evaluate to FALSE for lists (since
Hi Chris,
The survival package provides machinery for handling censored observations.
Whether time is censored or some other type of variable (e.g., viral load due
to some lower detection limit) does not make a fundamental difference. In fact,
the type of model you are thinking of with 2) is a
odels. Just explore these
packages to see what they can do.
Best,
Wolfgang
>-Original Message-
>From: Chris Evans [mailto:chrish...@psyctc.org]
>Sent: Tuesday, 21 December, 2021 12:56
>To: Viechtbauer, Wolfgang (SP)
>Cc: r-help@r-project.org
>Subject: Re: Creating NA equ
Hello all,
Say I would like to change the outcome in a formula to a variable not part of
the original dataset. This works just fine:
res <- lm(mpg ~ wt + cyl, data=mtcars)
res
y <- rnorm(nobs(x))
update(x, formula = y ~ .)
But not when doing so within a function:
rm(y)
f <- function(x) {
Dear Ashim,
If you really want to use lynx, then you need to open up a new terminal to make
this work. For example, this will do:
browseURL("http://www.r-project.org","xterm -e lynx")
But this will open up a new terminal for each call to browseURL().
Best,
Wolfgang
>-Original
41 matches
Mail list logo