bachlab / PsPM

A matlab suite for Psycho-Physiological Modelling
GNU General Public License v3.0
45 stars 11 forks source link

pspm_dcm incorrectly assign first value of dcm.stats to be always NaN #504

Closed teddychao closed 1 year ago

teddychao commented 1 year ago

Summary

Users have reported that pspm_dcm incorrectly assign first value of dcm.stats to be always NaN in the latest develop branch at the moment. This is suspected caused by the incorrect calculation of proc_subsessions in pspm_dcm, but relevant processing in pspm_dcm_inv may be also relevant. This is a critical issue and should be resolved asap.

dominikbach commented 1 year ago

The underlying cause is that trials statistics are excluded when there is any NaN data between trial start and trial end (around line 565). This should be changed - users would normally expect that when the NaN data are below the subsession threshold then the trial statistics are reported. This is an improvement, rather than a bug.

dominikbach commented 1 year ago

Actually, the problem the user reported is down to an indexing issue - it also happens with no missing data; so it's a bug. changed milestone to 6.1 accordingly.

dominikbach commented 1 year ago

Has been fixed in 6.1