You are here

metaSEM installation problem

7 posts / 0 new
Last post
Wojtek's picture
Offline
Joined: 04/04/2015 - 04:30
metaSEM installation problem

Hello,

I'm having problems when trying to install the metaSEM package. I'm a Mac user and I have the R 3.1.3 (Mavericks build) version. After having installed all packages required for metaSEM (OpenMx, MASS and ellipse), when trying to install the package directly, here's what I get :

install.packages("metaSEM")
Warning message:
package 'metaSEM' is not available (as a binary package for R version 3.1.3)

If, on the other hand, I follow Mike Cheung's instructions on his website (https://courses.nus.edu.sg/course/psycwlm/Internet/metaSEM/?#help), and I download the source package of metaSEM first, and try to install it from R, here's the output :

install.packages(pkgs="/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz", repos=NULL, type="source")
During startup - Warning messages:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_TIME failed, using "C"
3: Setting LC_MESSAGES failed, using "C"
4: Setting LC_MONETARY failed, using "C"
Warning: invalid package '/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz'
Error: ERROR: no packages specified
Warning message:
In install.packages(pkgs = "/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz", :
installation of package '/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz' had non-zero exit status

Could anyone help please ?
Wojtek

Mike Cheung's picture
Offline
Joined: 10/08/2009 - 22:37
Hi, Wojtek. Sorry. I am not a

Hi, Wojtek.

Sorry. I am not a Mac user. Other Mac users may provide more useful suggestions.

It seems that the following warning messages are not related to metaSEM:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_TIME failed, using "C"
3: Setting LC_MESSAGES failed, using "C"
4: Setting LC_MONETARY failed, using "C"

See http://stackoverflow.com/questions/9689104/installing-r-on-mac-warning-messages-setting-lc-ctype-failed-using-c and
http://stackoverflow.com/questions/27299420/how-to-get-rid-of-warning-messages-after-installing-r

Regarding the following errors, I am not sure whether the path is incorrect (no packages specified) or that you need to install some tools to build the source package (http://cran.r-project.org/doc/manuals/r-release/R-admin.html#OS-X).

Warning: invalid package '/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz'
Error: ERROR: no packages specified
Warning message:
In install.packages(pkgs = "/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz", :
installation of package '/Users/wswiatko/Google Drive/R/metaSEM/metaSEM_0.9-2.tar.gz' had non-zero exit status

The above are the suggestions from a non-Mac user.

Mike

Wojtek's picture
Offline
Joined: 04/04/2015 - 04:30
Hello Mr. Cheung

Hello Mr. Cheung,

Thanks a lot for your response. The links you provided were helpful to get rude of these not-metaSEM related warning messages.

Eventually, I manage to correctly install your package ! :) Actually, the real problem was in the R command used to install the package.
By default, as I downloaded the the source package from your website, the name of the file was metaSEM_0.9-2.tar . On the other hand, in the command that I used to install the package, install.packages(pkgs="/home/mike/metaSEM_0.9-2.tar.gz", repos=NULL, type="source”), there is also an extension within the file name, the “.gz” that shouldn’t be there. Once I deleted it, everything was ok.

Thanks again for your help !
Wojtek

fredli's picture
Offline
Joined: 05/01/2015 - 00:21
How to install metaSEM

I'm a biginner for R language and was having a hard time trying to install the metaSEM package into my PC. With Dr. Cheung's help, I figured/worked out the problems I had and would like to share the necessary steps to be taken for installing it correctly.First, browse a helpful documment that can be downloaded from the following IP:
https://courses.nus.edu.sg/course/psycwlm/Internet/metaSEM/index.html#installation-and-help
Secondly, the OpenMx should be installed.
Thirdly, download metaSEM for windows binary version(32 bit)and it is available at
https://dl.dropboxusercontent.com/u/25182759/metaSEM_0.9-2.zip
The alternative way to download it:
Download the devtools first and directly install it under R setting(Please refer to Dr. Cheung's documment for the metaSEM installation).
Finally, the downloaded R should be 3.1.2(2014).
This posting hopefully may benefit a beginning user of metaSEM for installing it, a great R package for conducting meta-analysis and SEM.

fredli's picture
Offline
Joined: 05/01/2015 - 00:21
data structure for metaSEM

Hi, metaSEM users:
Currently, I am working on meta-analysis using metaSEM. I noticed that there is a control statement for data set-up structure: .Dim = c(9L, 9L), indicating a matrix with 9 rows and 9 columns.
What is difference between .Dim = c(9, 9) and .Dim = c(9L, 9L)? It seems both work fine.
Could anyone help out this stupid question please ?

Fred

Mike Cheung's picture
Offline
Joined: 10/08/2009 - 22:37
Hi Fred,

Hi Fred,

9 can be either an integer or a floating point in R. 9L forces it to be an integer. For example,
> is.integer(9)
[1] FALSE
> is.integer(9L)
[1] TRUE

Since this question is neither related to metaSEM nor OpenMx, you may consider posting similar questions to
https://www.r-project.org/mail.html

Best,
Mike

fredli's picture
Offline
Joined: 05/01/2015 - 00:21
Dear Dr. Cheung:

Dear Dr. Cheung:
Greatly appreciated at helping out with this question !!
Best regards!!
Fred