Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • latent profile analysis, lclass not allowed

    Hi all,
    I'm trying out latent profile analysis with 8 continuous variables, I started by asking stata to give me 2 profiles:
    gsem (g9sharepower g9respect g9fair g9allsuccess g9mistake g9interesting g9easy <- ), lclass(C 2)

    But i got an error message: option lclass() not allowed

    Any suggestion would be appreciated, thanks!

  • #2
    Diane,

    This is an odd error. Stata has a stock dataset with several continuous indicators, and it does not replicate this error when I use your syntax. The only explanation I can imagine right now is that you are not running Stata 15. What version are you running?
    Please use the code delimiters to show code and results - use the # button on the formatting toolbar, between the " (double quote) and <> buttons.

    Please use the command -dataex- to show a representative sample of data; it is installed already if you have Stata 14.2 or 15.1, else you can install it by typing

    Code:
    ssc install dataex

    Comment


    • #3
      Hi Weiwen,
      Thanks for replying! I am indeed using stata 14.2 not 15, maybe that's why?

      Comment


      • #4
        Originally posted by Diane Hsieh View Post
        Hi Weiwen,
        Thanks for replying! I am indeed using stata 14.2 not 15, maybe that's why?
        Unfortunately, you do need Stata 15 to do latent class analysis in -gsem-. The Penn State University Stata plugin will work with Stata 14.2, and it does accept binary and ordinal indicators. However, the plugin won't work with continuous indicators. I am not aware of any user-written packages that enable generalized latent class analysis with many indicator types. Sorry to be the bearer of bad news! If you have to do this work and you can't get your hands on Stata 15, and if you don't know anyone with MPlus, then it can surely be done in R if you find the right package.
        Please use the code delimiters to show code and results - use the # button on the formatting toolbar, between the " (double quote) and <> buttons.

        Please use the command -dataex- to show a representative sample of data; it is installed already if you have Stata 14.2 or 15.1, else you can install it by typing

        Code:
        ssc install dataex

        Comment

        Working...
        X