You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dear Gaston,
I run into a bug when specifying the scaling argument in plpsm() for models that contain formative blocks (mode B) with 2 manifest variables (MVs).
The reason for this is comes from get_weights_nonmetric(), which is called whenever scaling is specified (even if all MVs are specified to be numerical).
In this function, the computation of X* when mode B is used is given by:
The problem is that when block_sizes[q] == 2, then QQ[[q]][,-p] won't be a matrix object, but a numeric vector, which causes the %*% operation to fail.
The fix is very simple: QQ[[q]][ -p, drop = FALSE ] should be used in the definition of X.star[,p]
Best regards,
G
The text was updated successfully, but these errors were encountered:
I forgot to mention that this is relevant for the development version of the package (30aaec0).
guilhemchalancon
changed the title
matrix operations with blocks of 2 MVs in get_weight_nonmetric()
matrix operations with blocks of 2 MVs in get_weights_nonmetric()
Mar 17, 2014
Dear Gaston,
I run into a bug when specifying the
scaling
argument inplpsm()
for models that contain formative blocks (mode B) with 2 manifest variables (MVs).The reason for this is comes from
get_weights_nonmetric()
, which is called wheneverscaling
is specified (even if all MVs are specified to be numerical).In this function, the computation of X* when mode B is used is given by:
Where
q
refers to the LV,p
to the MV.The problem is that when
block_sizes[q] == 2
, thenQQ[[q]][,-p]
won't be a matrix object, but a numeric vector, which causes the%*%
operation to fail.The fix is very simple:
QQ[[q]][ -p, drop = FALSE ]
should be used in the definition ofX.star[,p]
Best regards,
G
The text was updated successfully, but these errors were encountered: