Jack Tanner
unread,Apr 25, 2013, 4:16:22 PM4/25/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to stan-...@googlegroups.com
Are data dimensions known on the stan side when called from rstan? In
JAGS, if I pass in a data matrix Q, I can do
data {
Q_dim <- dim(Q)
n_rows <- Q_dim[1] // number of columns in Q
n_cols <- Q_dim[2] // number of rows in Q
}
This means I don't have to pass in n_rows and n_cols as separate data
entries.
But it looks like I can't do that in stan. If I declare
data {
int<lower=0,upper=1> y[N];
}
then N is not known. Can stan determine N from dimensions of y?