[Rcicr-users] calculating subject agreement; superimposing 'agreement regions' on base images
Nicholas Michalak
nickmm at umich.edu
Sun Jul 31 20:47:28 CEST 2016
Hi all
I've been try to recreate two analyses/procedures for reverse correlation
paradigm response data: calculating reliability (something like cronbach's
alpha), and superimposing regions of subject agreement on the base image
used in a given study.
In this mailing list I saw Dr. Dotsch recommend the following paper:
Éthier-Majcher, C., Joubert, S., & Gosselin, F. (2013). Reverse correlating
trustworthy faces in young and older adults. Frontiers in psychology, 4.
<http://dx.doi.org.proxy.lib.umich.edu/10.3389%2Ffpsyg.2013.00592>
The second paragraph in the results section (which begins "To increase
signal-to-noise ratio...") has the analysis I'm trying to recreate with my
own data. Figure 2 is the kind of image I'd like to make. Here's a summary
of the steps from that section:
- Calculate the Pearson correlations between every individual CI and the
corresponding group CI, restricting the computation to the union of areas
that attained statistical significance in all group CI's
- Transform these group CIs into Z-scores planes by dividing them by the
square root of the number of individuals in the appropriate subject
group. (*this
is the easy par*t)
- Superimpose the Z-scored group CIs onto a grayscale face.
- The bright red (Z-score ≥ 4.30) and bright blue blobs (Z-score ≤
−4.30), respectively, indicate regions where bright pixels were
significantly correlated positively with the judgment and regions where
dark pixels were significantly correlated negatively with the judgment
I contacted the corresponding author and he very generously gave me the
following Matlab code:
*% this creates the group ci:ci = 0;for subject = 1:nb_subjects,
... for trial = 1:nb_trials ...
ci = ci + (selected_noise-unselected_noise)/sqrt(2); end
ci = ci / sqrt(nb_trials);endci = ci/sqrt(nb_subjects);% the following
smooths the group ci:h = fspecial('gaussian’,ceil(6*sigma),sigma);smooth_ci
= filter2(h,ci) ;smooth_ci = smooth_ci / sqrt(sum(h(:).^2))*
I'm an R user and I'm struggling to translate this. I can get the noise
patterns from the ci data element from the rcicr batchGenerateCI2IFC()
function's output. The smoothie package in R has filter functions
like gauss2dsmooth(). That's as far as I've gotten.
I'd greatly appreciate any help navigating these procedures. Thank you!
Nick
--
Nick Michalak
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcicr-users/attachments/20160731/e09813a5/attachment.html>
More information about the Rcicr-users
mailing list