Skip to contents

A .out file's own INPUT INSTRUCTIONS section IS the exact Mplus syntax that produced it – unlike .spv (syntax recovered from a SEPARATE structure element), and like .smcl (a command echo IS the syntax). This materialises that block as a real .inp file (Mplus's own input-syntax extension), in a code subdirectory alongside the original .out file, so it is discoverable the same way an author's own saved .inp file would be – see .code_expand_mplus() in R/code_check.R, this function's only caller.

Usage

.mplus_export_syntax(out_path, code_dir_name = "code")

Arguments

out_path

path to the .out file

code_dir_name

name of the sibling code subdirectory to write into, relative to out_path's own directory. Default "code". A file of the user's own gets this folder in the temporary folder instead, so the user's folder is not changed (see .recovered_code_dir()).

Value

the path to the written .inp file, or NA_character_ if the file has no recoverable INPUT INSTRUCTIONS section.