Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Dear Prof. Epskamp,
May I propose some changes to
semPlot?A post in the lavaan Google Group (https://groups.google.com/g/lavaan/c/xnOqMUbUYfY/m/aZUQo1MYAgAJ) led me to issue #40 .
The error occurred with
ordered = TRUE. As one of the users pointed out, it is related to lavaan.R andlavaanNames().I am interested in this topic because I may also need to plot this kind of model. I took a look and it seems that you have already been working on this issue, which is related to the
conditional.xoption. The current error occurred due to two other matrices,ImpCovsandObsCovs, which do not match the names retrieved"ov"and need to use"ov.model", whenconditional.xis TRUE.This is an illustration of the error:
Created on 2024-11-15 with reprex v2.1.1
I tried to fix this problem based on what you have done:
sfcheung@1ee4f3c
It seems to work:
Created on 2024-11-15 with reprex v2.1.1
I am not sure whether these changes will break other things. If it will, I can try to see how to fix them.
Feel free to reject this PR if it does not fit your plan.
Thanks again for developing this package for SEM users.
-- Shu Fai