FCP-INDI / C-PAC

Configurable Pipeline for the Analysis of Connectomes
https://fcp-indi.github.io/
GNU Lesser General Public License v3.0
64 stars 41 forks source link

MDMR' Regressor file #836

Open BolinCao opened 6 years ago

BolinCao commented 6 years ago

Although the illustration is clear, I had some question about what the regressor file should have? what is the right form? This is the two error I meet. Error: Participant column can not be a regressor. Interface Function failed to run. Error: Participant column was not found in regressor file. Interface Function failed to run. Thank you for your attention.

anibalsolon commented 6 years ago

Hi @woerfu could you please send us your pipeline config, so we can take a look?

Basically, the regressor file must have a participant ID column so we can match the subject functional data with its phenotypic information, but the ID cannot be used as a regressor.

BolinCao commented 6 years ago

Thank you @anibalsolon. I am glad to receive your reply. The regressor file made me confused. I only run 3 subject to test and simulated phenotypic regressor a.

Path to a CSV file containing the phenotypic regressor.

mdmr_regressor_file : /media/cbl/data/var.csv

Name of the participants column in your regressor file.

@mdmr_regressor_participant_column : subject_id

Columns from the CSV file indicating factor variables. Other columns will be handled as covariates. Separated by commas.

mdmr_regressor_columns : a

Number of permutation tests to run on the Pseudo-F statistics.

mdmr_permutations : 500

Number of Nipype nodes created while computing MDMR. Dependent upon computing resources.

mdmr_parallel_nodes : 1 Then error occured. Error: index 45 is out of bounds for axis 0 with size 45

anibalsolon commented 6 years ago

Hi @woerfu

Could you please provide us with the full error message? It will help us to identify where in the code your problem is occurring.

YukiSakai1209 commented 5 years ago

Hi,

In my opinion, nifti_cwas function of cwas.py may be wrong.

subjects_data = np.array([ nb.load(subject_file).get_data().astype('float64')[mask_indices].T for subject_file in subject_files ])

should be changed into

subjects_data = np.array([ nb.load(subject_file).get_data().astype('float64')[mask_indices] for subject_file in subject_files ]).

In addition, in mdmr.py, following part might be confusing. Because participant id column is removed in cwas.py, the necessity of columns = columns.copy() + 1 depends on the order of participant id and columns of interest. X1 = np.hstack((np.ones((subjects, 1)), X)) columns = columns.copy() + 1