Skip to content

Prior sensitivity for Bayesian SEM model - #140

Open
AngeDakouri wants to merge 5 commits into
stan-dev:developmentfrom
AngeDakouri:main
Open

AngeDakouri wants to merge 5 commits into
stan-dev:developmentfrom
AngeDakouri:main

Conversation

@AngeDakouri

Copy link
Copy Markdown

I fixed the incompatibility between the blavaan and priorsense libraries.
In this way is possible to do sensitivity analyisis also for blavaan object

n-kall and others added 5 commits July 24, 2026 17:02
Here the stan file related to the SEM model (I add the prior calculations in the section generated quantities) and a pipeline to apply the prior sensitivity.
@n-kall

n-kall commented Sep 14, 2026

Copy link
Copy Markdown
Collaborator

Thank you for looking into this. It would be great to have priorsense compatible with blavaan. I am thinking about the best way to get this to work. It seems that you have provided new Stan code for blavaan models? So would this need to be changed in the the blavaan package to save the log_prior, rather than in priorsense?

@AngeDakouri

Copy link
Copy Markdown
Author

Yes, ideally when the blavaan model is generated the associated stan file should save the log prior in generated quantities section. But this is not happening. So to use priorsense I modified the stan model and the refitted the model with stan interface and thankfully the results were Identical. So if possible to save the log prior in generated quantities automatically is a great step.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants