I understand from your question that you are probably calling `mplusObject()` to create your Mplus model code. Let's say you create it and assign it to an object called `mp_model`; your code will look like, more or less:
```
mp_model <- mplusObject(...)
mp_fit <- mplusModeler(mp_model, ...)
```
If this is correct, I think you may have found a bug in how the `mplusObject()` function expands those weights (although I understand they wouldn't need to be expanded in the Mplus syntax
actually, as that syntax itself is valid for a continuous range of variables).
What you can probably do is first create the syntax from the `mplusObject`, then parse it (the call to `createSyntax()` can already do this for you), and then write the syntax to a temporary file and run it with `runModels()` instead of `mplusModeler()` i.e.:
```
mp_model <- mplusObject(...)
mp_syntax <- createSyntax(mp_model, filename = "model.inp", check = TRUE, add = TRUE) # The last two arguments will make it call
`parseMplus(mp_syntax,
add = TRUE)` for you
mp_fit <- runModels("model.inp")
```
I haven't tested this syntax, but I hope it points you in the correct direction at least.
Daniel