- In progress
nice_lavaanPlot(): Fixed title centering in all output formats (PNG, JPG, PDF, SVG) by:- Adding Graphviz centering attributes (ALIGN="CENTER", BALIGN="CENTER", labeljust="c", center="true")
- Refactoring to use
lavaanPlot:::buildCall()+DiagrammeR::grViz()for direct control over DOT diagram generation
save_plot(): Addeduse_webshotparameter (defaultTRUE) for browser-based rendering:- When
TRUE, uses webshot2 package (headless Chrome via chromote) for pixel-perfect rendering that matches RStudio viewer exactly - Avoids librsvg font substitution issues (Helvetica → DejaVu Sans) that cause text misalignment
- Supports PNG, JPG, and PDF formats; SVG uses rsvg directly
- Set
use_webshot = FALSEto use rsvg rendering instead (faster but may have font differences)
- When
save_plot(): Re-enabledadd_svg_padding()with horizontal-only padding to provide margin around plot content
- Add
save_plot()function to export/save plots fromnice_lavaanPlot()andnice_tidySEM()with multiple format options (PNG, PDF, SVG, JPG)
nice_lavaanPlot(): addtitle_size,note_size, andfit_stats_sizearguments to allow customization of font sizes for titles, notes, and fit statistics (useful for large diagrams where default sizes are too small to read)nice_lavaanPlot(): addwrap_widthargument to automatically wrap long text (title, note, fit statistics) at word boundaries, with intelligent adjustment based on font size to prevent text cutoff
nice_lavaanPlot(): addfit_statsandfit_stats_typearguments to optionally display fit statistics (CFI, TLI, RMSEA, SRMR, etc.) directly on the plot, with support for regular/scaled/robust types when using robust estimators
nice_lavaanPlot(): addtitleandnotearguments for HTML-safe Graphviz labels to display titles and captions without DOT parser errors
- New CRAN submission
lavaan_reg()andlavaan_defined(): addstandardized_seargument to allow bootstrap SE & CI for standardized coefficients (#38)
- New CRAN submission
- Fix bug in
nice_fit()that created an error with categorical variables (#37)
- Fix bug in
lavaan_defined()/lavaan_extract()that repeated the first cell on all other rows of the first column (#36)
- Now skips tests and examples when
DiagrammeRsvgis not installed
- CRAN resubmission to fix unicode problem
- New release + CRAN
- New paper in JOSS! Citation updated accordingly.
?lavaanExtranow works as expected.write_lavaan(): accepts a new argument,threshold, represented by the "|" operator.lavaan_ind()renames tolavaan_defined()because it was not specific to indirect effects but actually extracts any user-defined parameters such as total effects and moderated slopes using the:=operator.lavaan_reg()gets rid of the estimate argument, to comply with best practices of reporting both unstandardized and standardized parameters with their respective confidence intervals.- new function:
lavaan_extract(), which takes a specific operator and extracts relevant information (now used internally forlavaan_reg(),lavaan_defined(),lavaan_cov())
- CRAN resubmission
- New function:
nice_modindices, which outputs modification indices along item labels and a similarity score between the left-hand side and right-hand side items. Useful to assess item redundancy when considering modification indices.
- CRAN resubmission: suggested dependencies now check for the correct version with
rlang::check_installed().
- CRAN resubmission: tests now run even without suggested dependencies.
- CRAN resubmission
nice_tidySEM: new argument:reduce_items, to change the size of the nodes (boxes) of the items defining the latent variables (which often require less emphasis).
nice_tidySEM: now omit the leading zero when using standardized coefficients (for APA style).nice_fit:- Update fit indices recommendations from Schreiber et al. (2006) to Schreiber (2017). Only benchmark that has changed is RMSEA, moving to
< .05 [.00, .08]from< .06-.08 [.00, .10]. - Make table shorter by combining the RMSEA column and its confidence interval and shortening the AIC and BIC interpretations.
- Update fit indices recommendations from Schreiber et al. (2006) to Schreiber (2017). Only benchmark that has changed is RMSEA, moving to
lavaan_cov: renamed r column to covariance since in some cases standardized residual variances were not real correlations.- New function:
lavaan_cor, which is the same aslavaan_covbut only for actual correlations lavaan_reg,lavaan_ind, andlavaan_cov: new argumentestimatewhich can be either "B" to obtain standardized estimates and corresponding p values and confidence interval, or "b" for unstandardized values.nice_lavaanPlot: stars now appear not only for regression per default, but also for latent variables and covariancesc("regress", "latent", "covs").
nice_tidySEM: corrected a bug whereas if the layout contained columns named c("IV", "M", "DV"), it would remove any extra columns (such as items), explicitly ignoring part of the layout provided.nice_lavaanPlot: now default to black path lines instead of gray.
- In examples and internal tests, now check for package availability to satisfy CRAN requirements.
- Remove vignettes from package, to satisfy CRAN package size requirements (they are still available on the website however).
nice_fit: better error message when not providing a lavaan object.tmvnsimpackage now required for nice_tidySEM as it seems necessary to usetidySEM's new version.
nice_tidySEM: New argument to hide covariances:hide_cov(defaults toFALSE).
- CRAN resubmission
- Breaking changes:
- We remove the copied/reexported
save_as_docxand the like in favour of explicitly callingflextable::save_as_docx. This way we are not creating namespace conflicts for these functions, we are consistent with the new approach inrempsyc, and it also gives credit to theflextablepackage, as this is the powerhouse that produces the tables under the hood. nice_fitnow requires a list of models (or a single model), so it will not accept models loosely provided in the function as different arguments. This is because we get rid of the dot-dot-dot...argument in favour of supporting list objects.
- We remove the copied/reexported
nice_fitnow has an added footnote reference to Schreiber et al. (2006) for fit indices references when usingnice_table = TRUE.
nice_fit: gains amodel.labelsargument to customize the model names in the table.
lavaan_indgains an argument,underscores_to_arrows, to replace underscores by arrows for the indirect effect column, so that indirect effects are more quickly visually interpretable.nice_tidySEM: More meaningful error message when providing unmatching label names.nice_fitlook improved when usingnice_table = TRUE
- CRAN resubmission
rempsycpackage dependency is now on CRAN, so we can rely on it normally now (yeah!).- Adding test coverage (100% so far!).
- Preparing for CRAN.
nice_tidySEM: Gains thelabel_locationand...arguments.
nice_tidySEM: Corrected bug when not providing a structure/matrix layout.
- Added new function:
nice_tidySEM, for a quick and decent-lookingtidySEMplot with sensical (but customizable) defaults.
write_lavaan: Exciting news! Automatic indirect effects now seemingly support any combination of IV, moderator, and DV!
write_lavaan: Automatic indirect effects now support another scenario: two mediators and three IVs!
- Added new function:
nice_lavaanPlot, for a quick and decent-lookinglavaanPlotwith sensical (but customizable) defaults. write_lavaan: Automatic indirect effects now support another scenario: two mediators and two IVs!
write_lavaan: Fixed bug with automatic indirect effects when more than 1 mediator making forbidden paths (two mediators tested successfully)
cfa_fit_plot:- Adds ellipsis to pass any desired argument to
lavaan::cfa, and thus removes the defaultmissing = "fiml"which was causing a bug withestimator = DWLS. - Changes the default from saving to PDF to opening in RStudio Viewer, and adds an additional
save.as.pdfargument to save as PDF. - Now imports
flextable::save_as_docx(andsave_as_html,save_as_image,save_as_pptx...) to support saving thenice_fittables to Word without having to explicitly loadflextableorrempsyc. - Added package logo!
- Adds ellipsis to pass any desired argument to
- Added new function:
cfa_fit_plotto simultaneously print, save, and plot the CFA results.
- Added new arguments/symbols:
constraint.equal(==),constraint.smaller(<),constraint.larger(>),custom(accepts a single, lavaan-like string)
- Added automatic indirect effects
- First package version