khaivngo / QuickEval

GNU General Public License v2.0
3 stars 4 forks source link

Calculation method z-score (paired comparison) #142

Closed anauta00 closed 2 years ago

anauta00 commented 3 years ago

Hi,

Can you tell me where in your code I can find the precise calculation method which uses the cumulative score matrix to determine the z-scores?

I would like to duplicate the method in my C++ code. I read your article 'QuickEval a web application for psychometric scaling experiments' which explains things quite extensively but I would like to make sure I use the same method...

Thanks and greetings, Auke

anauta00 commented 3 years ago

Hi (again!),

I found the relevant code in the files "Paired.vue" and "maths.js". I will now translate the JavaScript code to C++.

Greetings, Auke

anauta00 commented 3 years ago

Hi,

Just a remark regarding the 95% confidence interval calculation, file "maths.js", function 'calculateSDMatrix()':

All the values in the generated vector 'SDArray' are equal. You could just calculate the first one and be done with it, I believe.

Here is my one line C++ code doing this: sdvec.push_back(1.96 * M_SQRT1_2 / sqrt(nobs)); // 'nobs': number of observations.

And may I ask why you use this error calculation and not the one from 'Montag':

    const double b1 = 1.76, b2 = -3.08, b3 = -0.613, b4 = 2.55, b5 = -0.491;
    double sdobs = b1 * pow(n - b2, b3) * pow(nobs - b4, b5);   // empirical standard deviation by 'Montag' ('n': numer of stimuli)
    ciM = 1.96 * sdobs; // 95% confidence value

Greetings, Auke

mariuspedersen commented 3 years ago

The Montag one could be used, but I we went with the one that has been more "standard". A possibility would be to give the option to change between them.