Tests for bidirectional dependence between pairs of lag sequential transitions.
bidirectional(data, labels = NULL, lag = 1, adjacent = TRUE,
tailed = 1, permtest = FALSE, nperms = 10)A one-column dataframe, or a vector of code sequences, or a square
frequency transition matrix. If data is not a frequency transition matrix,
then data must be either (a) a series of string (non-numeric) code values,
or (b) a series of integer codes with values ranging from "1" to what
ever value the user specifies in the "ncodes" argument. There should be no
code values with zero frequencies. Missing values are not permitted.
Optional argument for providing labels to the code values. Accepts
a list of string variables. If
unspecified, codes will be labeled "Code1", "Code2", etc.
The lag number for the analyses.
Can adjacent values be coded the same? Enter "FALSE" if adjacent events
can never be the same. Enter "TRUE" if adjacent events can always be the same.
Specify whether significance tests are one-tailed or two-tailed.
Options are "1" or "2".
Do you want to run permutation tests of significance? Options are
"FALSE" for no, or "TRUE" for yes. Warning: these computations can be time consuming.
The number of permutations per block.
A list with the following elements:
The transitional frequency matrix
The bidirectional frequencies
The expected bidirectional frequencies
The bidirectional kappas
The z values for the kappas
The p values (significance levels) for the kappas
This function tests the bidirectional dependence of behaviors i to j, and j to i, an additive sequential pattern described by Wampold and Margolin (1982) and Wampold (1989, 1992). Bidirectional dependence suggests a reciprocal effect of behaviors. That is, behavior i influences behavior j and behavior j influences behavior i. For example, if behavior i is a husband's positive behavior, and behavior j is his wife's positive behavior, a test of bidirectional dependence asks whether the husband reciprocates the wife's positive behavior, and the wife reciprocates the husband's positive behavior (See Margolin and Wampold, 1982). Bidirectional dependence is sometimes called a "circuit".
O'Connor, B. P. (1999). Simple and flexible SAS and SPSS programs for analyzing lag-sequential categorical data. Behavior Research Methods, Instrumentation, and Computers, 31, 718-726. Wampold, B. E., & Margolin, G. (1982). Nonparametric strategies to test the independence of behavioral states in sequential data. Psychological Bulletin, 92, 755-765. Wampold, B. E. (1989). Kappa as a measure of pattern in sequential data. Quality & Quantity, 23, 171-187. Wampold, B. E. (1992). The intensive examination of social interactions. In T. Kratochwill & J. Levin (Eds.), Single-case research design and analysis: New directions for psychology and education (pp. 93-131). Hillsdale, NJ: Erlbaum.
# NOT RUN {
bidirectional(data_Wampold_1982,
labels = c('HPos','HNeu','HNeg','WPos','WNeu','WNeg'),
permtest = TRUE, nperms = 100)
# }
Run the code above in your browser using DataLab