Generating DAG list from data using Population-Based Incremental learning
StrLearningPBIL_LDLRA(
U,
Z = NULL,
w = NULL,
na = NULL,
seed = 123,
ncls = 2,
method = "R",
population = 20,
Rs = 0.5,
Rm = 0.002,
maxParents = 2,
maxGeneration = 100,
successiveLimit = 5,
elitism = 0,
alpha = 0.05,
estimate = 1,
filename = NULL,
verbose = TRUE
)
Sample size. The number of rows in the dataset.
Length of the test. The number of items included in the test.
correct response ratio
adjacency matrix list
graph list
Learned Parameters.A three-dimensional array of patterns where item x rank x pattern.
Marginal Item Reference Matrix
IRP Indices which include Alpha, Beta, Gamma.
Test Reference Profile matrix.
latent Rank/Class Distribution
Rank/Class Membership Distribution
Overall fit index for the test.See also TestFit
Estimated parameters tables.
Correct Response Rate tables
Student information. It includes estimated class membership, probability of class membership, RUO, and RDO.
U is either a data class of exametrika, or raw data. When raw data is given, it is converted to the exametrika class with the dataFormat function.
Z is a missing indicator matrix of the type matrix or data.frame
w is item weight vector
na argument specifies the numbers or characters to be treated as missing values.
seed for random.
number of latent class(rank). The default is 2.
specify the model to analyze the data.Local dependence latent class model is set to "C", latent rank model is set "R". The default is "R".
Population size. The default is 20
Survival Rate. The default is 0.5
Mutation Rate. The default is 0.002
Maximum number of edges emanating from a single node. The default is 2.
Maximum number of generations.
Termination conditions. If the optimal individual does not change for this number of generations, it is considered to have converged.
Number of elites that remain without crossover when transitioning to the next generation.
Learning rate. The default is 0.05
In PBIL for estimating the adjacency matrix, specify by number from the following four methods: 1. Optimal adjacency matrix, 2. Rounded average of individuals in the last generation, 3. Rounded average of survivors in the last generation, 4. Rounded generational gene of the last generation. The default is 1.
Specify the filename when saving the generated adjacency matrix in CSV format. The default is null, and no output is written to the file.
verbose output Flag. default is TRUE
This function performs structural learning for each classes by using the Population-Based Incremental Learning model(PBIL) proposed by Fukuda et al.(2014) within the genetic algorithm framework. Instead of learning the adjacency matrix itself, the 'genes of genes' that generate the adjacency matrix are updated with each generation. For more details, please refer to Fukuda(2014) and Section 9.4.3 of the text(Shojima,2022).
Fukuda, S., Yamanaka, Y., & Yoshihiro, T. (2014). A Probability-based evolutionary algorithm with mutations to learn Bayesian networks. International Journal of Artificial Intelligence and Interactive Multimedia, 3, 7–13. DOI: 10.9781/ijimai.2014.311
# \donttest{
# Perform Structure Learning for LDLRA using PBIL algorithm
# This process may take considerable time due to evolutionary optimization
result.LDLRA.PBIL <- StrLearningPBIL_LDLRA(J35S515,
seed = 123, # Set random seed for reproducibility
ncls = 5, # Number of latent ranks
method = "R", # Use rank model (vs. class model)
elitism = 1, # Keep best solution in each generation
successiveLimit = 15 # Convergence criterion
)
# Examine the learned network structure
# Plot Item Response Profiles showing item patterns across ranks
plot(result.LDLRA.PBIL, type = "IRP", nc = 4, nr = 3)
# Plot Test Response Profile showing overall response patterns
plot(result.LDLRA.PBIL, type = "TRP")
# Plot Latent Rank Distribution showing student distribution
plot(result.LDLRA.PBIL, type = "LRD")
# }
Run the code above in your browser using DataLab