% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/compute_test_statistic.R
\name{compute_test_statistic}
\alias{compute_test_statistic}
\title{Compute the Test Statistic T for Brain Network Populations}
\usage{
compute_test_statistic(populations, a = 1)
}
\arguments{
\item{populations}{A named list where each element is a list of adjacency
matrices for a population. Example:
\code{list(Control = list(G1, G2, ...), PatientA = list(G1, G2, ...), PatientB = list(G1, G2, ...))}}

\item{a}{A normalization constant. Default is 1.}
}
\value{
A numeric value representing the test statistic T.
}
\description{
This function computes the test statistic T to assess whether different
populations of brain networks originate from the same distribution.
}
\examples{
# Generate synthetic populations data
Control <- list(
  generate_random_graph(n_nodes = 5, edge_prob = 0.1),
  generate_random_graph(n_nodes = 5, edge_prob = 0.1)
)
PatientA <- list(
  generate_random_graph(n_nodes = 5, edge_prob = 0.15),
  generate_random_graph(n_nodes = 5, edge_prob = 0.15)
)
PatientB <- list(
  generate_random_graph(n_nodes = 5, edge_prob = 0.2),
  generate_random_graph(n_nodes = 5, edge_prob = 0.2)
)

populations <- list(Control = Control, PatientA = PatientA, PatientB = PatientB)

# Compute the test statistic T
T_value <- compute_test_statistic(populations, a = 1)
print(T_value)
}
