Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

getPopulation

Extract the data generation population model underlying a result object


Description

This function will extract the data generation population model underlying a result object (linkS4class{SimResult}).

Usage

getPopulation(object, std = FALSE, improper = TRUE, nonconverged = FALSE)

Arguments

object

The result object that you wish to extract the data generation population model from (linkS4class{SimResult}).

std

If TRUE, standardized parameters are returned.

improper

Specify whether to include the information from the replications with improper solutions

nonconverged

Specify whether to include the information from the nonconvergent replications

Value

A data frame contained the population of each replication

Author(s)

Sunthud Pornprasertmanit (psunthud@gmail.com)

See Also

Examples

## Not run: 
loading <- matrix(0, 6, 1)
loading[1:6, 1] <- NA
LY <- bind(loading, "runif(1, 0.4, 0.9)")
RPS <- binds(diag(1))
RTE <- binds(diag(6))
CFA.Model <- model(LY = LY, RPS = RPS, RTE = RTE, modelType="CFA")

# We will use only 10 replications to save time.
# In reality, more replications are needed.
Output <- sim(10, n=200, model=CFA.Model)

# Get the population parameters
getPopulation(Output)

## End(Not run)

simsem

SIMulated Structural Equation Modeling

v0.5-16
GPL (>= 2)
Authors
Sunthud Pornprasertmanit [aut], Patrick Miller [aut], Alexander Schoemann [aut] (<https://orcid.org/0000-0002-8479-8798>), Terrence D. Jorgensen [aut, cre] (<https://orcid.org/0000-0001-5111-6773>), Corbin Quick [ctb]
Initial release
2021-03-28

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.