Dear list,

Hi, I am emailing to see if it would be possible to get some help on
running MCMCfactanal on R. I am trying to derive a single score measuring a
likelihood to recieve IMF loans from 8 different variables related to IMF
representation but for reason, my codes do not seem to take me to where I
want to be. For some reason my code drops certain rows ( countries)
automatically, making it impossible for me to acquires factor scores for
those observations. It would also be great if you could let me know if
MCMCfactanal is the program to use for my purposes and recommend me better
functions or codes if possible.
Thank you very much in advance and I look forward to any help.

Sincerely,
Haillie

I am pasting the codes I have used below.

# installing packages
install.packages("MCMCpack")
install.packages("foreign")
install.packages("reshape")
install.packages("car")

## calling libraries
library(MCMCpack)
library(foreign)

### this loads TeachingDemos pkg and allows me to save txts
library(TeachingDemos)
txtStart("imfproject7.txt",commands = TRUE, results = TRUE, append = FALSE)

## calling libraries
library(MCMCpack)
library(foreign)

## opening a data set on the desktop
setwd("C:/Users/haillie/Desktop")
imfdata<- read.csv("imfdata.csv")

##calling libraries
library(reshape)
library(car)


## factanal Code ( 1 dimension with continuous variable)
postimfdata<-MCMCfactanal(~shstaff+shquota+frusanew+trshusnew+frdfgnew+trsheunew+usbanksh+eubanksh,
factors=1, data=imfdata, burnin=20000, mcmc=200000, thin=100, verbose=1000,
seed = NA, lambda.start = NA, psi.start = NA, l0 = 0, L0 = 0, a0 = 0.001,
b0 = 0.001, store.lambda = FALSE, store.scores = TRUE, std.var = TRUE)

Sincerely,
Haillie

	[[alternative HTML version deleted]]

