Fri 21 Dec 2007 09:14:03 AM UTC, comment #8:
I checked this in.
|
Wed 19 Dec 2007 10:16:26 AM UTC, comment #7:
I couldn't reproduce exactly what you described but I noticed a similar problem. Basically what was happening was that the grouping value is getting copied only as far as the length of the string given in the syntax. Thus, if T-TEST is called twice, and the second call used a value shorter than that used in the first call, then problems occur.
Try this updated patch and see if you get better results. There's a lot of nasty kludges here. In particular it's only working because of the stipulation that the grouping variable can only be a short string. If we ever want to allow long string variables as the grouping variable, then a lot of code will have to be rewritten.
(file #14662)
|
Sat 15 Dec 2007 09:29:55 PM UTC, comment #6:
This worked, mostly. I entered data with two variables, one numeric, the other string. The string variable had 'a' and 'k' as values. I used this string variable to define the groups, and it ran without trouble.
Then I added more data in both columns, with a single missing value in one of the rows and re-ran the t-test. This time, the output told me one of the groups was defined by 'kk' instead of 'k', and that group had NAN's in its relevant rows. I thought it might have something to do with missing value, so I replaced the missing value with a float for one variable and a 'k' for the other, but the same problem occurred in the output.
I pasted the syntax, and it looked fine. The syntax contained no double 'k' in the groups variable. The double 'k' was only in the output.
> "But there are a number of places where we're gratuitously comparing values, without knowing they're semantics."
I'm guilty of a lot of this. I would love to have an easy way to compare such values that doesn't cause trouble.
|
Sat 15 Dec 2007 03:36:37 AM UTC, comment #5:
This rather messy patch fixes the problem.
It also highlights an issue which I think needs to be dealt with post 0.6.0, namely that of comparing values. I don't think it's meaningfull to compare values unless the format of the variable to which they belong is also known, and if it's a string variable, then we also need to know the encoding. But there are a number of places where we're gratuitously comparing values, without knowing they're semantics.
(file #14630)
|
Thu 13 Dec 2007 07:59:14 AM UTC, comment #4:
I've checked in this patch. I'll see what I can do about the remaining problem.
|
Wed 12 Dec 2007 08:07:03 PM UTC, comment #3:
It ran okay. That problem with the length of the group variable is a pain.
|
Wed 12 Dec 2007 12:22:34 PM UTC, comment #2:
I think this patch fixes all the gui related issues. It could use some rigorous testing.
It still leaves a problem in the T-TEST command itself, when the group variable is a string variable, and the grouping values are less than 8 bytes.
|
Mon 10 Dec 2007 10:30:23 AM UTC, comment #1:
There's actually several independent, yet related bugs here:
1. The OK/Paste buttons should be insensitive until the groups have been properly defined.
2. The syntax generator doesn't quote the group values when the groups variable is a string variable.
3. The T Test command is doing it's string compare wrong, so that it sees no members in either group.
4. When the groups variable is numeric, we should be given the option to specify groups by a cut point.
I'll get around to addressing these soon.
|
Sun 09 Dec 2007 04:01:01 PM UTC, original submission:
Enter 24 random integers in column 1, call it 'v1', numeric
type. Enter 24 letters in column 2, variable name 'v2',
type string, with values 'a' and 'k'.
Go to Analyze --> Compare Means --> Independent Samples T Test.
Choose v2 as the grouping variable and v1 as the dependent variable. Hit 'OK' and psppire gives a syntax error saying that
I must define groups. I don't remember what the other software
does, but I thought it would group by the two values of v2 if v2
had only two values. Anyway, I then hit the 'Define Groups' button
and defined group 1 by 'a' and group 2 by 'k', then hit OK, and OK
again, and psppire gave the error "Syntax error expecting string at `a'.
|