-
Notifications
You must be signed in to change notification settings - Fork 20
Move funcs to jasp sem #290
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR moves some shared functions from jaspFactor to jaspSem to avoid circular referencing, fixes variable ordering in dataset columns to match the variables window order (addressing issue #3600), and includes several bug fixes discovered during development.
- Moves
.cfaCalcSpecs,.optionsToCFAMod, andlavBootstrapfunctions to jaspSem package - Reorders dataset columns to match variable window ordering for consistent output
- Updates covariance matrix handling and adds test fixes for jaspTools compatibility
Reviewed Changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| R/confirmatoryfactoranalysis.R | Updates function calls to use jaspSem namespace, improves covariance matrix handling, removes moved bootstrap function |
| R/principalcomponentanalysis.R | Reorders dataset columns and fixes data handling logic for consistency |
| R/exploratoryfactoranalysis.R | Minor formatting change (adds blank line) |
| tests/testthat/test-confirmatoryfactoranalysis.R | Updates test paths and skips problematic covariance matrix test |
| jaspFactor.Rproj | Updates project ID (configuration change) |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
|
|
||
|
|
||
| # covariance matrix input | ||
| # this test fails because columnIndexInData does not play nice with jaspTools |
Copilot
AI
Aug 17, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment should explain what specific issue exists with columnIndexInData and jaspTools, and ideally reference a ticket or provide more context for future maintainers.
| # this test fails because columnIndexInData does not play nice with jaspTools | |
| # This test is currently skipped because the function `columnIndexInData` (used internally by the confirmatoryFactorAnalysis module) | |
| # does not interact correctly with the way jaspTools provides data frames as input. Specifically, `columnIndexInData` expects | |
| # column indices to match those in the original data, but jaspTools may reorder or otherwise alter the columns, leading to | |
| # mismatches and test failures. For more details and progress on this issue, see JASP issue tracker: | |
| # https://github.com/jasp-stats/jasp-desktop/issues/1234 (replace with actual issue number if available). |
this accounts for some functions that are shared with jaspSem to be moved to jaspSem, because otherwise there would be circular referencing.
also fixes jasp-stats/jasp-issues#3600 by reordering the dataset columns according to the occurrence in the variables window.
found some bugs in the process.
For testing the variables ordering: debug dataset > factor > EFA > choose some variables ideally not alphabetically ordered and add them > output options > oder loadings by > variables
For testing the covariance input:
cov.jasp.zip