I downloaded group average functional correlation
file: HCP_S900_820_rfMRI_MSMAll_groupPCA_d4500ROW_zcorr.dconn.nii

Some diagonal elements of the square matrix (91282x91282) are infinite
(Please see below).

I want to use this matrix in ananalysis; however, I am not sure how to
understand or deal with infinite diagonal values.

I appreciate any insight

Thanks,
Sang

======================

In [1]: import nibabel

In [2]: asdf =
nibabel.load('HCP_S900_820_rfMRI_MSMAll_groupPCA_d4500ROW_zcorr.dconn.nii')

In [3]: img = asdf.get_data()

In [4]: img.shape
Out[4]: (1, 1, 1, 1, 91282, 91282)

In [5]: S = img[0,0,0,0,:,:]

In [6]: S
Out[6]:
memmap([[  8.66434002e+00,   1.96847185e-01,   1.66294336e-01, ...,
          1.01449557e-01,   7.45474100e-02,   1.15624115e-01],
       [  1.96847185e-01,              inf,   3.36383432e-01, ...,
         -5.70017472e-03,  -5.49946353e-02,   3.72834280e-02],
       [  1.66294336e-01,   3.36383432e-01,              inf, ...,
         -4.45242636e-02,  -6.07097335e-02,  -1.51601573e-02],
       ...,
       [  1.01449557e-01,  -5.70017472e-03,  -4.45242636e-02, ...,
                     inf,   1.91883039e+00,   9.20160294e-01],
       [  7.45474100e-02,  -5.49946353e-02,  -6.07097335e-02, ...,
          1.91883111e+00,   8.31776619e+00,   8.82132888e-01],
       [  1.15624115e-01,   3.72833721e-02,  -1.51601573e-02, ...,
          9.20160294e-01,   8.82132888e-01,   8.66434002e+00]],
dtype=float32)

In [7]: S.diagonal()
Out[7]:
memmap([ 8.66434002,         inf,         inf, ...,         inf,
        8.31776619,  8.66434002], dtype=float32)

_______________________________________________
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users

Reply via email to