Skip to content

This repository contains the course project for the R language class during the Spring 2024 semester at Southern Medical University.

License

Notifications You must be signed in to change notification settings

KaishinShaw/DynamicPCA-Updates

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DynamicPCA-Updates

This repository contains the course project for the R language class during the Spring 2024 semester at Southern Medical University.

Project Description

The project focuses on implementing two fast algorithms for dynamic PCA (Principal Component Analysis) updates: recursive and stochastic gradient methods. The codebase also includes auxiliary functions designed to update the sample mean and covariance.

Key Features

  • Recursive PCA Update Algorithm: Efficiently updates principal components as new data arrives, using a recursive methodology.
  • Stochastic Gradient PCA Update Algorithm: Implements a more randomized approach to updating principal components, which can be advantageous in large-scale applications.
  • Performance Evaluation of Recursive PCA: The accuracy (RMSE & RSE) and timing (User & Elapsed) of the Recursive PCA have been thoroughly tested. Comparative visualizations using ggplot2 illustrate the differences and potential advantages over the traditional PCA approach using the Eigen method.
  • Utility Functions: Functions to update the sample mean and sample covariance, essential for maintaining accurate PCA in dynamic environments. Includes a Timer implemented using closures to efficiently track and manage the performance and timing of updates, ensuring minimal overhead and maximal efficiency.

Current Challenges

  • Convergence Issue in secular_pca Solver: We have identified that the secular_pca solver does not always converge within a finite number of iterations under certain conditions. This issue is currently under investigation, and further research and debugging are needed to resolve this problem.

Goals for Improvement

  • Enhance Solver Stability: Investigate and enhance the stability and reliability of the secular_pca solver.
  • Optimize Performance: Continuous optimization of the algorithms to handle larger datasets more efficiently.
  • Expand Documentation: Improve documentation to provide clear usage instructions and examples.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.


This repository is an academic project and is part of the ongoing learning and research in dynamic PCA methods at Southern Medical University. Contributions that help improve the functionality and accuracy of these PCA update algorithms are highly appreciated.

About

This repository contains the course project for the R language class during the Spring 2024 semester at Southern Medical University.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published