Skip to content

Commit d6afa25

Browse files
Update readme
1 parent a0ed69e commit d6afa25

File tree

2 files changed

+60
-57
lines changed

2 files changed

+60
-57
lines changed

README.md

Lines changed: 40 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@ Version](https://www.r-pkg.org/badges/version/bgms)](https://cran.r-project.org/
77
[![Total](https://cranlogs.r-pkg.org/badges/grand-total/bgms)](https://cran.r-project.org/package=bgms)
88
<!-- badges: end -->
99

10-
# bgms: Bayesian Analysis of Networks of Binary and/or Ordinal Variables
10+
# bgms <a href="https://bayesiangraphicalmodeling.com"><img src="inst/bgms_sticker.svg" height="200" align="right" /></a>
1111

12-
<a href="https://bayesiangraphicalmodeling.com"><img src="inst/bgms_sticker.svg" height="200" align="right" /></a>
12+
**Bayesian analysis of graphical models with binary and ordinal
13+
variables**
1314

1415
The **bgms** package implements Bayesian estimation and model comparison
1516
for **ordinal Markov random fields (MRFs)**, graphical models that
@@ -63,57 +64,47 @@ You can also access these directly from R with:
6364

6465
``` r
6566
browseVignettes("bgms")
67+
#> No vignettes found by browseVignettes("bgms")
6668
```
6769

6870
## Why use Markov Random Fields?
6971

70-
Multivariate analysis using graphical models has received much attention
71-
in the recent psychological and psychometric literature (Contreras et
72-
al., 2019; Marsman & Rhemtulla, 2022; Robinaugh et al., 2020). Most of
73-
these graphical models are Markov Random Field (MRF) models, whose graph
74-
structure reflects the partial associations between variables
75-
(Kindermann & Snell, 1980). In these models, a missing edge between two
76-
variables in the network implies that these variables are independent,
77-
given the remaining variables (Lauritzen, 2004). In other words, the
78-
remaining variables of the network fully account for the potential
79-
association between the unconnected variables.
80-
81-
## Why use a Bayesian approach to analyze the MRF?
82-
83-
Testing the structure of the MRF in a one-sample design requires us to
84-
determine the plausibility of the opposing hypotheses of conditional
85-
dependence and conditional independence. That is, how plausible is it
86-
that the observed data come from a network with a structure that
87-
includes the edge between two variables compared to a network structure
88-
that excludes that edge? Similarly, testing for group differences in the
89-
MRF in an independent-samples design requires us to determine the
90-
plausibility of the opposing hypotheses of parameter difference and
91-
parameter equivalence. That is, how plausible is it that the observed
92-
data come from MRFs with differences in specific edge weights or
93-
threshold parameters compared to MRFs that do not differ in these
94-
parameter?
95-
96-
Frequentist approaches are limited in this respect because they can only
97-
reject, not support, null hypotheses of conditional independence or
98-
parameter equivalence. This leads to the problem that if an edge is
99-
excluded, we do not know whether this is because the edge is absent in
100-
the population or because we do not have enough data to reject the null
101-
hypothesis of independence. Similarly, if a difference is excluded, we
102-
do not know whether this is because there is no difference in the
103-
parameter between the different groups or because we do not have enough
104-
data to reject the null hypothesis of parameter equivalence.
105-
106-
To avoid this problem, we will advocate a Bayesian approach using Bayes
107-
factors. In one-sample designs, the inclusion Bayes factor (Huth et al.,
108-
2023; Sekulovski et al., 2024) allows us to quantify how much the data
109-
support both conditional dependence -<em>evidence of edge
110-
presence</em> - or conditional independence -<em>evidence of edge
111-
absence</em>. It also allows us to conclude that there is limited
112-
support for either hypothesis - an <em>absence of evidence</em>. In
113-
independent-sample designs, they can be used to quantify how much the
114-
data support the hypotheses of parameter difference and equivalence. The
115-
output of the <strong>bgm</strong> and <strong>bgmCompare</strong>
116-
functions can be used to estimate these inclusion Bayes factors.
72+
Graphical models or networks have become central in recent psychological
73+
and psychometric research (Contreras et al., 2019; Marsman & Rhemtulla,
74+
2022; Robinaugh et al., 2020). Most are **Markov random field (MRF)**
75+
models, where the graph structure reflects partial associations between
76+
variables (Kindermann & Snell, 1980).
77+
78+
In an MRF, a missing edge between two variables implies **conditional
79+
independence** given the rest of the network (Lauritzen, 2004). In other
80+
words, the remaining variables fully explain away any potential
81+
association between the unconnected pair.
82+
83+
## Why use a Bayesian approach?
84+
85+
When analyzing an MRF, we often want to compare competing hypotheses:
86+
87+
- **Edge presence vs. edge absence** (conditional dependence
88+
vs. independence) in one-sample designs.
89+
- **Parameter difference vs. parameter equivalence** in
90+
independent-sample designs.
91+
92+
Frequentist approaches are limited in such comparisons: they can reject
93+
a null hypothesis, but they cannot provide evidence *for* it.
94+
As a result, when an edge or difference is excluded, it remains unclear
95+
whether this reflects true absence or simply insufficient power.
96+
97+
Bayesian inference avoids this problem.
98+
Using **inclusion Bayes factors** (Huth et al., 2023; Sekulovski et al.,
99+
2024), we can quantify evidence in both directions:
100+
101+
- **Evidence of edge presence** vs. **evidence of edge absence**, or
102+
- **Evidence of parameter difference** vs. **evidence of parameter
103+
equivalence**.
104+
105+
This makes it possible not only to detect structure and group
106+
differences, but also to conclude when there is an *absence of
107+
evidence*.
117108

118109
## Installation
119110

Readme.Rmd

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ library(bgms)
2323
[![Total](https://cranlogs.r-pkg.org/badges/grand-total/bgms)](https://cran.r-project.org/package=bgms)
2424
<!-- badges: end -->
2525

26-
# bgms: Bayesian Analysis of Networks of Binary and/or Ordinal Variables
27-
28-
<a href="https://bayesiangraphicalmodeling.com"><img src="inst/bgms_sticker.svg" height="200" align="right" /></a>
26+
# bgms <a href="https://bayesiangraphicalmodeling.com"><img src="inst/bgms_sticker.svg" height="200" align="right" /></a>
27+
28+
**Bayesian analysis of graphical models with binary and ordinal variables**
2929

3030
The **bgms** package implements Bayesian estimation and model comparison for
3131
**ordinal Markov random fields (MRFs)**, graphical models that represent
@@ -79,15 +79,27 @@ browseVignettes("bgms")
7979

8080
## Why use Markov Random Fields?
8181

82-
Multivariate analysis using graphical models has received much attention in the recent psychological and psychometric literature [@RobinaughEtAl_2020; @MarsmanRhemtulla_2022_SIintro; @ContrerasEtAl_2019]. Most of these graphical models are Markov Random Field (MRF) models, whose graph structure reflects the partial associations between variables [@KindermannSnell1980]. In these models, a missing edge between two variables in the network implies that these variables are independent, given the remaining variables [@Lauritzen2004]. In other words, the remaining variables of the network fully account for the potential association between the unconnected variables.
82+
Graphical models or networks have become central in recent psychological and psychometric research [@RobinaughEtAl_2020; @MarsmanRhemtulla_2022_SIintro; @ContrerasEtAl_2019]. Most are **Markov random field (MRF)** models, where the graph structure reflects partial associations between variables [@KindermannSnell1980].
83+
84+
In an MRF, a missing edge between two variables implies **conditional independence** given the rest of the network [@Lauritzen2004]. In other words, the remaining variables fully explain away any potential association between the unconnected pair.
85+
86+
## Why use a Bayesian approach?
87+
88+
When analyzing an MRF, we often want to compare competing hypotheses:
89+
90+
- **Edge presence vs. edge absence** (conditional dependence vs. independence) in one-sample designs.
91+
- **Parameter difference vs. parameter equivalence** in independent-sample designs.
8392

84-
## Why use a Bayesian approach to analyze the MRF?
93+
Frequentist approaches are limited in such comparisons: they can reject a null hypothesis, but they cannot provide evidence *for* it.
94+
As a result, when an edge or difference is excluded, it remains unclear whether this reflects true absence or simply insufficient power.
8595

86-
Testing the structure of the MRF in a one-sample design requires us to determine the plausibility of the opposing hypotheses of conditional dependence and conditional independence. That is, how plausible is it that the observed data come from a network with a structure that includes the edge between two variables compared to a network structure that excludes that edge? Similarly, testing for group differences in the MRF in an independent-samples design requires us to determine the plausibility of the opposing hypotheses of parameter difference and parameter equivalence. That is, how plausible is it that the observed data come from MRFs with differences in specific edge weights or threshold parameters compared to MRFs that do not differ in these parameter?
96+
Bayesian inference avoids this problem.
97+
Using **inclusion Bayes factors** [@HuthEtAl_2023_intro; @SekulovskiEtAl_2024], we can quantify evidence in both directions:
8798

88-
Frequentist approaches are limited in this respect because they can only reject, not support, null hypotheses of conditional independence or parameter equivalence. This leads to the problem that if an edge is excluded, we do not know whether this is because the edge is absent in the population or because we do not have enough data to reject the null hypothesis of independence. Similarly, if a difference is excluded, we do not know whether this is because there is no difference in the parameter between the different groups or because we do not have enough data to reject the null hypothesis of parameter equivalence.
99+
- **Evidence of edge presence** vs. **evidence of edge absence**, or
100+
- **Evidence of parameter difference** vs. **evidence of parameter equivalence**.
89101

90-
To avoid this problem, we will advocate a Bayesian approach using Bayes factors. In one-sample designs, the inclusion Bayes factor [@HuthEtAl_2023_intro; @SekulovskiEtAl_2024] allows us to quantify how much the data support both conditional dependence -<em>evidence of edge presence</em> - or conditional independence -<em>evidence of edge absence</em>. It also allows us to conclude that there is limited support for either hypothesis - an <em>absence of evidence</em>. In independent-sample designs, they can be used to quantify how much the data support the hypotheses of parameter difference and equivalence. The output of the <strong>bgm</strong> and <strong>bgmCompare</strong> functions can be used to estimate these inclusion Bayes factors.
102+
This makes it possible not only to detect structure and group differences, but also to conclude when there is an *absence of evidence*.
91103

92104
## Installation
93105

0 commit comments

Comments
 (0)