Gengrui-Zhang / R2spa

An R Package for Two-Stage Path Analysis (2S-PA)
https://gengrui-zhang.github.io/R2spa/
Other
0 stars 0 forks source link

Add `casewise_residuals()` method #58

Open marklhc opened 1 year ago

marklhc commented 1 year ago
          @Gengrui-Zhang This may be a good reference:

https://www.statmodel.com/examples/webnotes/webnote%2020.pdf

After re-reading the Hallgren et al. paper and the web note, I think for scatter plots, we should

a. Default to using factor scores (or observed variables) from the input data b. Given the confusion about which trend line to add (e.g., model-implied or data-driven), I think it's best not to add a trend line. c. Create a function to compute casewise residuals (see semdplot).

Originally posted by @marklhc in https://github.com/Gengrui-Zhang/R2spa/issues/23#issuecomment-1582960068