[R] multinom and stargazer

jjgrover jjgrover at bsu.edu
Sun Jan 20 23:12:17 CET 2013

I am trying to create a LaTex table based on a multinom (nnet) object using
the stargazer command.
I have created a small data frame to demonstration the problem:

data <- data.frame(age=1:21, hight=20:40,
data$ed <- as.factor(data$ed)

I then make a multinomial model using the command multinom from the nnet

model <- multinom(ed ~ age + hight, data=data)
summary(model, Wald=TRUE)

However, when I attempt to use the stargazer command (from the stargazer
package) I get the following result:


% Table created by StarGazer v.2.0.1 by Marek Hlavac, Harvard University.
E-mail: hlavac at fas.harvard.edu
% Date and time: Sun, Jan 20, 2013 - 17:08:45
\begin{table}[htb] \centering 

\hline \\[-1.8ex] 
 & \multicolumn{1}{c}{\textit{Dependent variable:}} \\ 
\\[-1.8ex] & ed \\ 
\\[-1.8ex] & \textit{multinomial log-linear} \\ 
 & \textit{(neural networks)} \\ 
\hline \\[-1.8ex] 
Error: subscript out of bounds

In other threads the "Error: subscript out of bounds" is related to a
subsetting problem. Something about the program trying to fit 100 elements
into 50 slots. 

Since I am unsure of the process stargazer is using to create the table (or
even what the table is supposed to look like in the end) I don't know where
to start looking for errors. I am also still new to LaTex and R.

Any help would be greatly appreciated.


View this message in context: http://r.789695.n4.nabble.com/multinom-and-stargazer-tp4656117.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list