Dear all, ? I've only (very) recently started to use R (so please be easy on me if I may omit to mention relevant information or have overlooked fairly basic steps to solving the problem, since I do not have a lot of experience) because I'm interested in multinomial processing tree modeling with the TreeBUGS package (Heck, Arnold & Arnold 2017 - TreeBUGS: An R package for hierarchical multinomial-processing-tree modeling). I have attempted to conduct a permutation test with my dataset, as described on pages 5-6 of the paper. I've brought the data in the necessary long format (participant case in column 1, stimulus index in column 2, observed response in column 3) and specified the tree structure as described in the paper, in my case four trees with two possible responses each. When specifying the test, I am given the message: ? Error in M[, tree] : subscript out of bounds ? Though I've found some information on this general error online, all of it applies to different tests and didn't help me to solve the problem. Has anyone of you encountered this error before, or has a suggestion for me? ? Best, Max
TreeBUGS - subscript out of bounds
2 messages · Max Hennig, Eric Berger
Hi Max, Here's an example that will generate that error. Maybe it will point you to your problem. # create a 2x2 matrix
m <- matrix(1:4,nrow=2)
# refer to column 3 - which does not exist
m[,3]
# Error in m[, 3] : subscript out of bounds HTH, Eric
On Wed, Feb 21, 2018 at 4:35 PM, Max Hennig <MaxHennig13 at gmx.de> wrote:
Dear all, I've only (very) recently started to use R (so please be easy on me if I may omit to mention relevant information or have overlooked fairly basic steps to solving the problem, since I do not have a lot of experience) because I'm interested in multinomial processing tree modeling with the TreeBUGS package (Heck, Arnold & Arnold 2017 - TreeBUGS: An R package for hierarchical multinomial-processing-tree modeling). I have attempted to conduct a permutation test with my dataset, as described on pages 5-6 of the paper. I've brought the data in the necessary long format (participant case in column 1, stimulus index in column 2, observed response in column 3) and specified the tree structure as described in the paper, in my case four trees with two possible responses each. When specifying the test, I am given the message: Error in M[, tree] : subscript out of bounds Though I've found some information on this general error online, all of it applies to different tests and didn't help me to solve the problem. Has anyone of you encountered this error before, or has a suggestion for me? Best, Max
______________________________________________ R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/ posting-guide.html and provide commented, minimal, self-contained, reproducible code.