Learn R Programming

LSTMfactors (version 1.0.0)

Determining the Number of Factors in Exploratory Factor Analysis by LSTM

Description

A method for factor retention using a pre-trained Long Short Term Memory (LSTM) Network, which is originally developed by Hochreiter and Schmidhuber (1997) , is provided. The sample size of the dataset used to train the LSTM model is 1,000,000. Each sample is a batch of simulated response data with a specific latent factor structure. The eigenvalues of these response data will be used as sequential data to train the LSTM. The pre-trained LSTM is capable of factor retention for real response data with a true latent factor number ranging from 1 to 10, that is, determining the number of factors.

Copy Link

Version

Install

install.packages('LSTMfactors')

Version

1.0.0

License

GPL-3

Maintainer

Haijiang Qin

Last Published

July 7th, 2025

Functions in LSTMfactors (1.0.0)

LSTM

A pre-trained Long Short Term Memory (LSTM) Network for Determining the Number of Factors
load.scaler

Load the Scaler for the pre-trained Long Short Term Memory (LSTM) Network
data.datasets.LSTM

Subset Dataset for Training the Pre-Trained Long Short Term Memory (LSTM) Network
af.softmax

An Activation Function: Softmax
data.DAPCS

20-item Dependency-Oriented and Achievement-Oriented Psychological Control Scale (DAPCS)
normalizor

Feature Normalization
check_python_libraries

Check and Install Python Libraries (numpy and onnxruntime)
load.LSTM

Load the pre-trained Long Short Term Memory (LSTM) Network
extractor.feature

Extracting features for the pre-trained Long Short Term Memory (LSTM) Network
data.scaler.LSTM

the Scaler for the Pre-Trained Long Short Term Memory (LSTM) Network
plot.LSTM

Plot LSTM Classification Probability Distribution
print.LSTM

Print LSTM Results