Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

JASP Issue: "NaN" Appearing for effect sizes and descriptives in 2-sample t-tests

Hello,

I am having an odd issue in JASP. When there is a dataset with 3 or more conditions, and I use the filtering option to select just two to run an independent samples t-test, I often get "NaN" for the effect size and the descriptives, even though the actual t-test itself runs normally. Have others experienced this? The screenshot demonstrates the problem. Furthermore, as you'll see, the two conditions listed in the descriptives section are different from the ones that were selected and on which the t-test is based.

Comments

  • Hi Amsa,

    Thanks for reporting this!
    I think you forgot to attach the screenshot. Also, if order to detect whether there is a bug, and then fix it, it would be really great if you could report this on our GitHub page (for details see https://jasp-stats.org/2018/03/29/request-feature-report-bug-jasp/).

    Cheers,
    E.J.

  • Sorry, I forgot to add the screenshot! As you'll see, the conditions selected were HW and NW, but the descriptives table states LW and HW (and of course, all those NaNs).

  • Hi Amsa,

    Would it be possible for you to upload the jasp-file that you used to make this screenshot? Because some of the NaN's look sort of reasonable, especially where the LW's are specifically named (because there a division by zero occurs). However, without seeing the options for your analyses it is hard to guess wheter they should be there or not.

    I am guessing not, but it would be very helpful to see it in live-action.

    Best regards,
    Joris

  • Thanks Joris! Would it be fine for me to email some of the data to you as a JASP file? Alternatively, once we publish the manuscript, we will in any case be making the whole data set publicly available. We've also done analysis in R, so we have the information that we need (we are citing both R and JASP in the acknowledgements).

    You mention one point about divisions by zero being an explanation for the NaNs. But that's the other problem: The LW condition was completely filtered out of the analysis (see the top left hand, where LW has been crossed out). So, LW shouldn't be in the analysis at all (Actually, n in LW = 131). Rather, the descriptives table should be stating HW and NW, not HW and LW. This is what's most odd - JASP shouldn't be listing LW at all in that table, but since it does, the fact that it says that n = 0 in LW suggests that JASP also knows this variable has been filtered out.

    But then - the t-test itself is (correctly) based on the comparison between HW and NW.

    So, as a summary: 1) LW is filtered out, 2) the t-test is (correctly) between HW and NW, 3) the Cohen's d associated with this correct t-test is NaN, 3) in the descriptives table, LW is incorrectly mentioned when it should be NW (but the fact that LW = 0 in the descriptives table is correct, since it was filtered out).

    Sorry for the length of this message!

  • I've send you a PM with my email-address.

  • Hey amsa,

    I've taken a look at the jasp-file you sent me and I see you are using 0.9.1. When I reran your analysis in 0.9.2 the data was corrected, this was a small bug that we already fixed.
    So maybe you can try it with 0.9.2 and see if this solves your problem?

    Thanked by 1EJ
  • Yes, this has solved the issue! Thank you very much!

Sign In or Register to comment.