IBM Support

The GROUPS subcommand specifies an unknown variable or a long string variable.

Troubleshooting


Problem

T-Test analysis with Unicode on fails.

Symptom

[ERROR]
The GROUPS subcommand specifies an unknown variable or a long string variable. This subcommand must specify either a numeric variable or a short string variable. Text found: gender
Execution of this command stops.

Cause

A string variable that is larger than 8, will fail the T-Test analysis.

Diagnosing The Problem

[Example]
You run the following T-Test Syntax:
T-TEST GROUPS=GENDER ('F' 'M')
/MISSING=ANALYSIS
/VARIABLES=age weight
/CRITERIA=CI(.95).

* The locale and Unicode settings are : locale = en_IE.windows-1252 (en_IE) Unicode = yes

I receive the following error in my output window:
"The GROUPS subcommand specifies an unknown variable or a long string variable. This subcommand must specify either a numeric variable or a short string variable. Text found: gender
Execution of this command stops."

When I switch Unicode off the problem doesn't show up anymore and the analysis result is visible in the output view.

Is this a known bug ?

Resolving The Problem

No, this is not a defect.
When working in Unicode mode it is necessary to review/consider the string length as byte length is different for Unicode mode compared to locale mode.
In this example the String Length of GENDER is larger than 8.
On independent samples T-Test it is allowed to use SHORT strings as grouping variable.
A short string is of length <= 8.
Whereas the string length Gender in this case is larger than 8. This is not a problem in local mode; however, it is not possible in Unicode mode.

If you want to perform the T-Test when running in Unicode you simply must run this command before the T-Test. Then it will work in Unicode mode as well.


ALTER TYPE GENDER (A8).

[{"Product":{"code":"SSLVMB","label":"IBM SPSS Statistics"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"--","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Not Applicable","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}},{"Product":{"code":"SSLVMB","label":"IBM SPSS Statistics"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Not Applicable","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
16 June 2018

UID

swg21696817