MARTER: Simulation of Random Walk Model with 8 X 8 Transition Matrix and 8 X 8 Error Matrix

MARKOV TRANSITION MATRIX--Rows are true state on trial n; cols are true state on trial n + 1
  Standard Model Violation Model
ERRORS for True and Error Model
e1 = e2 = e3 =
ERROR TRANSITION MATRIX-- rows are true state; cols are observed response
No. trials=
DATA for True States
DATA2 for Error-filled Responses

Markov Model with Response Errors

This program was written to simulate models, such as described in Birnbaum (2013, Appendix B). That paper dealt with tests of transitivity with three choices. However, it can be used for other applications of a Markov process on 8 states. All of the code is included in this file. A simulator that satisfies iid is also available at this link.

This program is discussed and used in a paper by Birnbaum and Wan (submitted). The default values are those for the condition in that paper called Intrans 2, which is a special case of an intransitive model.

Instructions for Using the Program

The first row and first column contain labels of the true states. The entry in row i and column j represents the transition probability from state i on Trial n to State j on Trial n + 1. The last column contains the sum of the transition probabilities. After the "prepare" button is pressed, these values should be equal (within computer precision) to 1. The default labels represents a case of three item choice task, presented twice within each block.

In the current version of the program, one of the 8 states is chosen randomly as the starting value.

Quick Start to fit a MARTER model with the Default Values

1. Push the button "prepare" under the Markov transition matrix.

2. Scroll down to the Errors Matrix, and push the button "calculate errors by TE".

3. Push the button "row sums errors".

4. Push the button "10000 trials with error".

The true states will appear in the first box, and the error filled data will be in the second box below the true states. They are selected and focused, so you can use Control & C to copy them to another program, such as Excel.

(The default values are set up to run an intransitive model in which three preference patterns are possible: 111, 221, and 222. From the 111 state, one can transition only to 221 or stay in the 111 state; from the 221 state it is possible to transition to 111 or 222 (or remain in 221), and from the 222 state one can either stay in 222 or transition to 221. From all other states, there is a transition to one of these three states. )

The MARKOV transition Matrix

1. You can leave the transition matrix as given, or enter your own transition probabilities, but the values in each row must sum to 1. After you have completed the transition matrix, push the button labeled, prepare. This will read in the probabilities of transmission and find their cumulative sums, displaying the row sums in the last column. The transition probabilities must sum to 1, and if they do not sum to 1, then you should reload the page and re-enter probabilities that do in fact sum to 1. You should reload the program if you need to start over.

2. In standard mode, the default, there is no transition between replications. That is, replications are true replications in which the same state underlies both response patterns. The button Violation model, if clicked, will cause another Markov transition to occur within the two replications of a block (i.e., within a line of output data). This button allows one to explore consequences of this type of violation of the model. (In standard mode, the button labeled, 10,000 Trials, will create 10,000 simulations with two replications (i.e., 10,000 successive Markov transitions), and put them in the data window. In violation mode, this button creates 20,000 simulations of the Markov process, since an additional transition occurs within the block.)

3. The default in the error matrix is 0 error, so the results in the two data textareas should be the same; i.e., the true states are the same as the "error-filled" states, because probabilities of errors are all zero.
When the simulations are complete, the data are already selected, and the focus already is on the data window. To copy these data to another application, such as Excel, simply use CONTROL & C, and then CONTROL & V to copy and paste into the application. In Excel, it might be necessary to use the Text to Columns feature.

Instructions for Markov Process combined with Error

The matrix of errors contains the state labels in the first row and column, the same as for the Markov transition matrix. The entry in Row i and Column j contains the probability of showing the Observed response of Column j given the True State was that of Row i. This error matrix is assumed to be the same on all trials.

To run the Error feature, complete step 1 above, and do the following:

1. Either click the Calculate errors by TE button, having entered error probabilities for Items 1, 2, and 3, respectively. (This TE feature assumes that the rows and columns are labeled with integers of 1 and 2, as in the default starting set up), OR enter in the 8 X 8 matrix, the 64 error transition probabilities you want. The sum of the entries in each row should be 1.

2. Now push the row sums errors button. The row sums should be 1; if not, start the program again and enter errors that do, in fact, sum to 1 in each row. Then push the row sums button again.

3. Finally, push 10,000 trials with error to run 10,000 simulations. The first data matrix contains the TRUE states, and the second data matrix contains the OBSERVED responses, which contain error.
When the simulations are complete, the data are already selected, and the focus already is on the data window. To copy these data to another application, such as Excel, simply use CONTROL & C, and then CONTROL & V to copy and paste into the application. In Excel, it might be necessary to use the Text to Columns feature.

References

Birnbaum, M. H. (2013). True-and-error models violate independence and yet they are testable. Judgment and Decision Making, 8, 717-737. (See especially Appendix B).

Birnbaum, M. H. (2019). Bayesian and frequentist analysis of True and Error models. Judgment and Decision Making, 14(5), 608-616.

Birnbaum, M. H., & Bahra, J. P. (2012a). Separating response variability from structural inconsistency to test models of risky decision making, Judgment and Decision Making, 7, 402-426.

Birnbaum, M. H., & Bahra, J. P. (2012b). Testing transitivity of preferences in individuals using linked designs. Judgment and Decision Making, 7, 524-567.

Birnbaum, M. H., & Diecidue, E. (2015). Testing a class of models that includes majority rule and regret theories: Transitivity, recycling, and restricted branch independence. Decision, 2, 145-190.

Birnbaum, M. H., Navarro-Martinez, D., Ungemach, C., Stewart, N. & Quispe-Torreblanca, E. G. (2016). Risky decision making: Testing for violations of transitivity predicted by an editing mechanism. Judgment and Decision Making, 11, 75-91.

Birnbaum, M. H., & Quispe-Torreblanca, E. G. (2018). TEMAP2.R: True and error model analysis program in R. Judgment and Decision Making, 13(5), 428-440.

Birnbaum, M. H., & Wan, L. (submitted). MARTER: Markov Chain True and Error Model of Drifting Parameters. Judgment and Decision Making, x, xx-xx. (submitted).

This program was written by Michael Birnbaum and Lucy Wan; Michael wrote the Markov process, and Lucy added the TE error transition feature and other improvements.

Revised 11-9-19