bidirectional: bidirectional

Description Usage Arguments Details Value Author(s) References Examples

Description

Tests for bidirectional dependence between pairs of lag sequential transitions.

Usage

1
2
bidirectional(data, labels = NULL, lag = 1, adjacent = TRUE, 
              tailed = 1, permtest = FALSE, nperms = 10)

Arguments

data

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.

labels

Optional argument for providing labels to the code values. Accepts a list of string variables. If unspecified, codes will be labeled "Code1", "Code2", etc.

lag

The lag number for the analyses.

adjacent

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.

tailed

Specify whether significance tests are one-tailed or two-tailed. Options are "1" or "2".

permtest

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.

nperms

The number of permutations per block.

Details

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".

Value

A list with the following elements:

freqs

The transitional frequency matrix

bifreqs

The bidirectional frequencies

expbifreqs

The expected bidirectional frequencies

kappas

The bidirectional kappas

z

The z values for the kappas

pk

The p values (significance levels) for the kappas

Author(s)

Zakary A. Draper & Brian P. O'Connor

References

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.

Examples

1
2
3
bidirectional(data_Wampold_1982, 
              labels = c('HPos','HNeu','HNeg','WPos','WNeu','WNeg'),
              permtest = TRUE, nperms = 100)

Example output

Lag Sequential Analysis Tests for Bidirectional Dependence


The code frequencies:

data
 1  2  3  4  5  6 
60 40 20 50 20 10 


Cell Frequencies, Row & Column Totals, & N

       HPos HNeu HNeg WPos WNeu WNeg Totals
HPos     10   14    7   20    6    3     60
HNeu     12    6    3   13    4    2     40
HNeg      9    4    3    1    2    1     20
WPos     20   11    4    6    6    3     50
WNeu      6    4    2    5    2    0     19
WNeg      3    1    1    5    0    0     10
Totals   60   40   20   50   20    9    199


Observed Bidirectional Frequencies

     HPos HNeu HNeg WPos WNeu WNeg
HPos   20   26   16   40   12    6
HNeu   26   12    7   24    8    3
HNeg   16    7    6    5    4    2
WPos   40   24    5   12   11    8
WNeu   12    8    4   11    4    0
WNeg    6    3    2    8    0    0


Expected Bidirectional Frequencies

     HPos HNeu HNeg WPos WNeu WNeg
HPos   36   24   12   30   12    6
HNeu   24   16    8   20    8    4
HNeg   12    8    4   10    4    2
WPos   30   20   10   25   10    5
WNeu   12    8    4   10    4    2
WNeg    6    4    2    5    2    1


Bidirectional Kappas

      HPos  HNeu  HNeg  WPos  WNeu  WNeg
HPos -0.19  0.04  0.14  0.14  0.00  0.00
HNeu  0.04 -0.06 -0.12  0.07  0.00 -0.25
HNeg  0.14 -0.12  0.06 -0.50  0.00  0.00
WPos  0.14  0.07 -0.50 -0.18  0.03  0.20
WNeu  0.00  0.00  0.00  0.03  0.00 -1.00
WNeg  0.00 -0.25  0.00  0.20 -1.00 -0.06


z values for the bidirectional Kappas

      HPos  HNeu  HNeg  WPos  WNeu  WNeg
HPos -3.51  0.52  1.42  2.36  0.00  0.00
HNeu  0.52 -1.21 -0.41  1.11  0.00 -0.57
HNeg  1.42 -0.41  1.10 -1.89  0.00  0.00
WPos  2.36  1.11 -1.89 -3.29  0.38  1.58
WNeu  0.00  0.00  0.00  0.38  0.00 -1.53
WNeg  0.00 -0.57  0.00  1.58 -1.53 -1.05


Requested 'tail' (1 or 2) for Significance Tests = 1 


Significance Levels for the Bidirectional Kappas

       HPos   HNeu   HNeg   WPos   WNeu   WNeg
HPos 0.0002 0.3018 0.0773 0.0091 0.5000 0.5000
HNeu 0.3018 0.1124 0.3404 0.1333 0.5000 0.2843
HNeg 0.0773 0.3404 0.1346 0.0293 0.5000 0.5000
WPos 0.0091 0.1333 0.0293 0.0005 0.3526 0.0574
WNeu 0.5000 0.5000 0.5000 0.3526 0.5000 0.0636
WNeg 0.5000 0.2843 0.5000 0.0574 0.0636 0.1465


Data Permutation Significance Levels (number of permutations = 100)

     HPos HNeu HNeg WPos WNeu WNeg
HPos 0.00 0.45 0.12 0.01 1.00 1.00
HNeu 0.45 0.29 0.42 0.16 1.00 0.38
HNeg 0.12 0.42 0.36 0.02 1.00 1.00
WPos 0.01 0.16 0.02 0.02 0.40 0.05
WNeu 1.00 1.00 1.00 0.40 1.00 0.11
WNeg 1.00 0.38 1.00 0.05 0.11 0.62

LagSequential documentation built on May 16, 2019, 5:09 p.m.