spm-python 25.1a1.dev1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (834) hide show
  1. spm/__init__.py +828 -0
  2. spm/__wrapper__.py +343 -0
  3. spm/_spm/_spm.ctf +0 -0
  4. spm/file_array.py +529 -0
  5. spm/gifti.py +570 -0
  6. spm/meeg.py +1198 -0
  7. spm/nifti.py +412 -0
  8. spm/slover.py +597 -0
  9. spm/spm.py +63 -0
  10. spm/spm_ADEM.py +57 -0
  11. spm/spm_ADEM_M_set.py +53 -0
  12. spm/spm_ADEM_diff.py +27 -0
  13. spm/spm_ADEM_set.py +20 -0
  14. spm/spm_ADEM_update.py +25 -0
  15. spm/spm_ALAP.py +159 -0
  16. spm/spm_A_reduce.py +26 -0
  17. spm/spm_BIDS.py +29 -0
  18. spm/spm_BMS.py +43 -0
  19. spm/spm_BMS_F.py +28 -0
  20. spm/spm_BMS_F_smpl.py +21 -0
  21. spm/spm_BMS_bor.py +28 -0
  22. spm/spm_BMS_gibbs.py +29 -0
  23. spm/spm_Bcdf.py +56 -0
  24. spm/spm_Bpdf.py +56 -0
  25. spm/spm_Ce.py +34 -0
  26. spm/spm_DEM.py +100 -0
  27. spm/spm_DEM_F.py +22 -0
  28. spm/spm_DEM_M_set.py +58 -0
  29. spm/spm_DEM_R.py +28 -0
  30. spm/spm_DEM_diff.py +27 -0
  31. spm/spm_DEM_embed.py +23 -0
  32. spm/spm_DEM_eval.py +48 -0
  33. spm/spm_DEM_eval_diff.py +27 -0
  34. spm/spm_DEM_generate.py +36 -0
  35. spm/spm_DEM_int.py +27 -0
  36. spm/spm_DEM_qH.py +25 -0
  37. spm/spm_DEM_qP.py +20 -0
  38. spm/spm_DEM_qU.py +23 -0
  39. spm/spm_DEM_set.py +20 -0
  40. spm/spm_DEM_z.py +24 -0
  41. spm/spm_DFP.py +87 -0
  42. spm/spm_DFP_plot.py +19 -0
  43. spm/spm_DesMtx.py +213 -0
  44. spm/spm_DesRep.py +128 -0
  45. spm/spm_DisplayTimeSeries.py +67 -0
  46. spm/spm_Dpdf.py +32 -0
  47. spm/spm_ECdensity.py +18 -0
  48. spm/spm_FcUtil.py +136 -0
  49. spm/spm_Fcdf.py +72 -0
  50. spm/spm_Fpdf.py +65 -0
  51. spm/spm_GDEM.py +117 -0
  52. spm/spm_Gcdf.py +71 -0
  53. spm/spm_Gpdf.py +63 -0
  54. spm/spm_Icdf.py +78 -0
  55. spm/spm_Ipdf.py +76 -0
  56. spm/spm_KL_cat.py +23 -0
  57. spm/spm_KL_dir.py +26 -0
  58. spm/spm_LAP.py +99 -0
  59. spm/spm_LAPF.py +77 -0
  60. spm/spm_LAPS.py +77 -0
  61. spm/spm_LAP_F.py +24 -0
  62. spm/spm_LAP_eval.py +26 -0
  63. spm/spm_LAP_iS.py +21 -0
  64. spm/spm_LAP_pg.py +19 -0
  65. spm/spm_LAP_ph.py +19 -0
  66. spm/spm_Laplace.py +32 -0
  67. spm/spm_MB_col.py +16 -0
  68. spm/spm_MDP_MI.py +26 -0
  69. spm/spm_MDP_da.py +18 -0
  70. spm/spm_MH.py +28 -0
  71. spm/spm_MH_reml.py +28 -0
  72. spm/spm_MH_reml_likelihood.py +20 -0
  73. spm/spm_Markov_blanket.py +30 -0
  74. spm/spm_Menu.py +24 -0
  75. spm/spm_NESS_F.py +35 -0
  76. spm/spm_NESS_ds.py +35 -0
  77. spm/spm_NESS_gen.py +48 -0
  78. spm/spm_NESS_gen_lap.py +44 -0
  79. spm/spm_Ncdf.py +61 -0
  80. spm/spm_Ncdf_jdw.py +32 -0
  81. spm/spm_Npdf.py +52 -0
  82. spm/spm_P.py +41 -0
  83. spm/spm_PEB.py +68 -0
  84. spm/spm_P_Bonf.py +35 -0
  85. spm/spm_P_FDR.py +87 -0
  86. spm/spm_P_RF.py +59 -0
  87. spm/spm_P_clusterFDR.py +26 -0
  88. spm/spm_P_peakFDR.py +38 -0
  89. spm/spm_Pcdf.py +69 -0
  90. spm/spm_Pec_resels.py +21 -0
  91. spm/spm_Ppdf.py +63 -0
  92. spm/spm_Q.py +31 -0
  93. spm/spm_Q_perm.py +15 -0
  94. spm/spm_ROI.py +30 -0
  95. spm/spm_SpUtil.py +266 -0
  96. spm/spm_Tcdf.py +71 -0
  97. spm/spm_Tpdf.py +56 -0
  98. spm/spm_VBX.py +45 -0
  99. spm/spm_VOI.py +63 -0
  100. spm/spm_Volt_W.py +17 -0
  101. spm/spm_Volterra.py +33 -0
  102. spm/spm_Welcome.py +16 -0
  103. spm/spm_XYZreg.py +177 -0
  104. spm/spm_XYZreg_Ex2.py +44 -0
  105. spm/spm_Xcdf.py +60 -0
  106. spm/spm_Xpdf.py +57 -0
  107. spm/spm_affine_priors.py +17 -0
  108. spm/spm_ancova.py +35 -0
  109. spm/spm_api_bmc.py +25 -0
  110. spm/spm_ar_reml.py +30 -0
  111. spm/spm_argmax.py +26 -0
  112. spm/spm_atlas.py +27 -0
  113. spm/spm_authors.py +17 -0
  114. spm/spm_axis.py +13 -0
  115. spm/spm_barh.py +18 -0
  116. spm/spm_bayes2_logbf.py +20 -0
  117. spm/spm_beta_compare.py +27 -0
  118. spm/spm_betaln.py +24 -0
  119. spm/spm_bilinear.py +36 -0
  120. spm/spm_bilinear_condition.py +16 -0
  121. spm/spm_bireduce.py +46 -0
  122. spm/spm_bms_against_null.py +20 -0
  123. spm/spm_bms_anova.py +31 -0
  124. spm/spm_bms_anova_img.py +21 -0
  125. spm/spm_bms_compare_groups.py +26 -0
  126. spm/spm_bms_display.py +22 -0
  127. spm/spm_bms_display_ROI.py +20 -0
  128. spm/spm_bms_display_vox.py +18 -0
  129. spm/spm_bms_partition.py +22 -0
  130. spm/spm_bms_test_null.py +20 -0
  131. spm/spm_bms_ttest.py +31 -0
  132. spm/spm_browser.py +21 -0
  133. spm/spm_bsplinc.py +43 -0
  134. spm/spm_bsplins.py +49 -0
  135. spm/spm_bwlabel.py +30 -0
  136. spm/spm_cat.py +31 -0
  137. spm/spm_cat_struct.py +15 -0
  138. spm/spm_cell_swap.py +16 -0
  139. spm/spm_changepath.py +28 -0
  140. spm/spm_check_filename.py +17 -0
  141. spm/spm_check_installation.py +26 -0
  142. spm/spm_check_orientations.py +22 -0
  143. spm/spm_check_registration.py +22 -0
  144. spm/spm_check_results.py +19 -0
  145. spm/spm_check_version.py +75 -0
  146. spm/spm_circularGraph.py +23 -0
  147. spm/spm_clf.py +27 -0
  148. spm/spm_cli.py +14 -0
  149. spm/spm_clusters.py +25 -0
  150. spm/spm_colourmap.py +46 -0
  151. spm/spm_combinations.py +18 -0
  152. spm/spm_compact_svd.py +18 -0
  153. spm/spm_compare_families.py +54 -0
  154. spm/spm_cond_units.py +17 -0
  155. spm/spm_conman.py +247 -0
  156. spm/spm_contrasts.py +21 -0
  157. spm/spm_conv.py +25 -0
  158. spm/spm_conv_full.py +24 -0
  159. spm/spm_conv_vol.py +41 -0
  160. spm/spm_convmtx.py +27 -0
  161. spm/spm_copy.py +25 -0
  162. spm/spm_coreg.py +57 -0
  163. spm/spm_cov2corr.py +15 -0
  164. spm/spm_create_vol.py +16 -0
  165. spm/spm_cross.py +23 -0
  166. spm/spm_csd_fmri_gu.py +21 -0
  167. spm/spm_csd_fmri_mar.py +34 -0
  168. spm/spm_csd_fmri_mtf.py +36 -0
  169. spm/spm_cva.py +77 -0
  170. spm/spm_cva_ui.py +92 -0
  171. spm/spm_dartel_integrate.py +30 -0
  172. spm/spm_data_hdr_read.py +18 -0
  173. spm/spm_data_hdr_write.py +16 -0
  174. spm/spm_data_id.py +17 -0
  175. spm/spm_data_read.py +32 -0
  176. spm/spm_data_write.py +22 -0
  177. spm/spm_dcm_HMM.py +58 -0
  178. spm/spm_dcm_HMM_plot.py +30 -0
  179. spm/spm_dcm_J.py +78 -0
  180. spm/spm_dcm_KL.py +21 -0
  181. spm/spm_dcm_U.py +33 -0
  182. spm/spm_dcm_average.py +42 -0
  183. spm/spm_dcm_bdc.py +55 -0
  184. spm/spm_dcm_bma.py +98 -0
  185. spm/spm_dcm_bma_results.py +17 -0
  186. spm/spm_dcm_bmc.py +45 -0
  187. spm/spm_dcm_bmc_peb.py +80 -0
  188. spm/spm_dcm_bmr.py +49 -0
  189. spm/spm_dcm_bmr_all.py +78 -0
  190. spm/spm_dcm_bpa.py +53 -0
  191. spm/spm_dcm_check_stability.py +23 -0
  192. spm/spm_dcm_compare.py +17 -0
  193. spm/spm_dcm_connectivity_ui.py +26 -0
  194. spm/spm_dcm_contrasts.py +20 -0
  195. spm/spm_dcm_create.py +33 -0
  196. spm/spm_dcm_csd_Q.py +43 -0
  197. spm/spm_dcm_delay.py +38 -0
  198. spm/spm_dcm_diagnose.py +44 -0
  199. spm/spm_dcm_display.py +20 -0
  200. spm/spm_dcm_estimate.py +65 -0
  201. spm/spm_dcm_evidence.py +26 -0
  202. spm/spm_dcm_fit.py +29 -0
  203. spm/spm_dcm_fmri_check.py +57 -0
  204. spm/spm_dcm_fmri_csd.py +50 -0
  205. spm/spm_dcm_fmri_csd_DEM.py +50 -0
  206. spm/spm_dcm_fmri_csd_data.py +25 -0
  207. spm/spm_dcm_fmri_csd_gen.py +21 -0
  208. spm/spm_dcm_fmri_csd_results.py +31 -0
  209. spm/spm_dcm_fmri_graph_gen.py +19 -0
  210. spm/spm_dcm_fmri_image.py +17 -0
  211. spm/spm_dcm_fmri_mar.py +47 -0
  212. spm/spm_dcm_fmri_mode.py +23 -0
  213. spm/spm_dcm_fmri_mode_gen.py +23 -0
  214. spm/spm_dcm_fmri_nmm.py +61 -0
  215. spm/spm_dcm_fmri_priors.py +38 -0
  216. spm/spm_dcm_generate.py +32 -0
  217. spm/spm_dcm_graph.py +18 -0
  218. spm/spm_dcm_graph_functional.py +21 -0
  219. spm/spm_dcm_identify.py +18 -0
  220. spm/spm_dcm_load.py +23 -0
  221. spm/spm_dcm_loo.py +43 -0
  222. spm/spm_dcm_mdp.py +44 -0
  223. spm/spm_dcm_mtf.py +35 -0
  224. spm/spm_dcm_optimise.py +36 -0
  225. spm/spm_dcm_peb.py +108 -0
  226. spm/spm_dcm_peb_bmc.py +108 -0
  227. spm/spm_dcm_peb_bmc_fam.py +50 -0
  228. spm/spm_dcm_peb_con.py +53 -0
  229. spm/spm_dcm_peb_fit.py +82 -0
  230. spm/spm_dcm_peb_full.py +83 -0
  231. spm/spm_dcm_peb_review.py +20 -0
  232. spm/spm_dcm_peb_rnd.py +51 -0
  233. spm/spm_dcm_peb_rnd_search.py +51 -0
  234. spm/spm_dcm_peb_test.py +56 -0
  235. spm/spm_dcm_peb_to_gcm.py +61 -0
  236. spm/spm_dcm_post_hoc.py +85 -0
  237. spm/spm_dcm_post_hoc_old.py +79 -0
  238. spm/spm_dcm_ppd.py +48 -0
  239. spm/spm_dcm_reduce.py +15 -0
  240. spm/spm_dcm_review.py +29 -0
  241. spm/spm_dcm_search.py +44 -0
  242. spm/spm_dcm_sessions.py +36 -0
  243. spm/spm_dcm_simulate.py +42 -0
  244. spm/spm_dcm_sparse.py +51 -0
  245. spm/spm_dcm_sparse_priors.py +23 -0
  246. spm/spm_dcm_specify.py +107 -0
  247. spm/spm_dcm_specify_ui.py +40 -0
  248. spm/spm_dcm_ui.py +77 -0
  249. spm/spm_dcm_voi.py +25 -0
  250. spm/spm_dctmtx.py +39 -0
  251. spm/spm_ddiff.py +38 -0
  252. spm/spm_deface.py +21 -0
  253. spm/spm_defaults.py +33 -0
  254. spm/spm_deformations.py +21 -0
  255. spm/spm_dem2dcm.py +29 -0
  256. spm/spm_design_contrasts.py +29 -0
  257. spm/spm_design_factorial.py +23 -0
  258. spm/spm_design_flexible.py +23 -0
  259. spm/spm_design_within_subject.py +21 -0
  260. spm/spm_detrend.py +23 -0
  261. spm/spm_dftmtx.py +25 -0
  262. spm/spm_diag.py +17 -0
  263. spm/spm_diag_array.py +17 -0
  264. spm/spm_dicom_convert.py +46 -0
  265. spm/spm_dicom_essentials.py +21 -0
  266. spm/spm_dicom_header.py +35 -0
  267. spm/spm_dicom_headers.py +25 -0
  268. spm/spm_dicom_metadata.py +24 -0
  269. spm/spm_dicom_text_to_dict.py +30 -0
  270. spm/spm_diff.py +38 -0
  271. spm/spm_diff_dx.py +23 -0
  272. spm/spm_diffeo.py +464 -0
  273. spm/spm_dilate.py +40 -0
  274. spm/spm_dir_MI.py +24 -0
  275. spm/spm_dir_norm.py +19 -0
  276. spm/spm_dir_sort.py +21 -0
  277. spm/spm_dirichlet_exceedance.py +32 -0
  278. spm/spm_dot.py +32 -0
  279. spm/spm_dwtmtx.py +24 -0
  280. spm/spm_dx.py +57 -0
  281. spm/spm_dx_eig.py +57 -0
  282. spm/spm_ecat2nifti.py +19 -0
  283. spm/spm_eeg_artefact.py +50 -0
  284. spm/spm_eeg_artefact_events.py +27 -0
  285. spm/spm_eeg_artefact_eyeblink.py +28 -0
  286. spm/spm_eeg_artefact_flat.py +27 -0
  287. spm/spm_eeg_artefact_heartbeat.py +29 -0
  288. spm/spm_eeg_artefact_jump.py +27 -0
  289. spm/spm_eeg_artefact_nans.py +27 -0
  290. spm/spm_eeg_artefact_peak2peak.py +27 -0
  291. spm/spm_eeg_artefact_saccade.py +33 -0
  292. spm/spm_eeg_artefact_threshchan.py +27 -0
  293. spm/spm_eeg_artefact_zscore.py +27 -0
  294. spm/spm_eeg_artefact_zscorediff.py +27 -0
  295. spm/spm_eeg_assemble_priors.py +19 -0
  296. spm/spm_eeg_average.py +29 -0
  297. spm/spm_eeg_average_TF.py +30 -0
  298. spm/spm_eeg_avgfreq.py +24 -0
  299. spm/spm_eeg_avgtime.py +26 -0
  300. spm/spm_eeg_bc.py +30 -0
  301. spm/spm_eeg_cfc.py +30 -0
  302. spm/spm_eeg_collapse_timefreq.py +24 -0
  303. spm/spm_eeg_combineplanar.py +31 -0
  304. spm/spm_eeg_contrast.py +37 -0
  305. spm/spm_eeg_convert.py +59 -0
  306. spm/spm_eeg_convert2images.py +43 -0
  307. spm/spm_eeg_convert_ui.py +17 -0
  308. spm/spm_eeg_copy.py +22 -0
  309. spm/spm_eeg_correct_sensor_data.py +28 -0
  310. spm/spm_eeg_crop.py +26 -0
  311. spm/spm_eeg_definetrial.py +32 -0
  312. spm/spm_eeg_dipoles_ui.py +15 -0
  313. spm/spm_eeg_displayECD.py +30 -0
  314. spm/spm_eeg_display_tf.py +17 -0
  315. spm/spm_eeg_downsample.py +30 -0
  316. spm/spm_eeg_epochs.py +59 -0
  317. spm/spm_eeg_filter.py +35 -0
  318. spm/spm_eeg_firstlevel.py +21 -0
  319. spm/spm_eeg_fixpnt.py +15 -0
  320. spm/spm_eeg_ft2spm.py +15 -0
  321. spm/spm_eeg_fuse.py +25 -0
  322. spm/spm_eeg_grandmean.py +36 -0
  323. spm/spm_eeg_history.py +32 -0
  324. spm/spm_eeg_inv_Mesh2Voxels.py +38 -0
  325. spm/spm_eeg_inv_check.py +23 -0
  326. spm/spm_eeg_inv_checkdatareg.py +17 -0
  327. spm/spm_eeg_inv_checkforward.py +15 -0
  328. spm/spm_eeg_inv_checkmeshes.py +21 -0
  329. spm/spm_eeg_inv_custom_ui.py +31 -0
  330. spm/spm_eeg_inv_datareg.py +43 -0
  331. spm/spm_eeg_inv_datareg_ui.py +22 -0
  332. spm/spm_eeg_inv_extract.py +25 -0
  333. spm/spm_eeg_inv_extract_ui.py +19 -0
  334. spm/spm_eeg_inv_fmripriors.py +40 -0
  335. spm/spm_eeg_inv_forward.py +22 -0
  336. spm/spm_eeg_inv_forward_ui.py +23 -0
  337. spm/spm_eeg_inv_get_vol_sens.py +23 -0
  338. spm/spm_eeg_inv_group.py +38 -0
  339. spm/spm_eeg_inv_headcoordinates.py +24 -0
  340. spm/spm_eeg_inv_icp.py +41 -0
  341. spm/spm_eeg_inv_imag_api.py +17 -0
  342. spm/spm_eeg_inv_image_display.py +18 -0
  343. spm/spm_eeg_inv_mesh.py +23 -0
  344. spm/spm_eeg_inv_mesh_spherify.py +28 -0
  345. spm/spm_eeg_inv_mesh_ui.py +26 -0
  346. spm/spm_eeg_inv_prep_modes_xval.py +35 -0
  347. spm/spm_eeg_inv_results.py +24 -0
  348. spm/spm_eeg_inv_results_display.py +15 -0
  349. spm/spm_eeg_inv_results_ui.py +19 -0
  350. spm/spm_eeg_inv_rigidreg.py +22 -0
  351. spm/spm_eeg_inv_spatnorm.py +23 -0
  352. spm/spm_eeg_inv_transform_mesh.py +18 -0
  353. spm/spm_eeg_inv_transform_points.py +15 -0
  354. spm/spm_eeg_inv_vb_ecd_gui.py +49 -0
  355. spm/spm_eeg_inv_vbecd.py +41 -0
  356. spm/spm_eeg_inv_vbecd_disp.py +22 -0
  357. spm/spm_eeg_inv_vbecd_getLF.py +28 -0
  358. spm/spm_eeg_inv_vbecd_gui.py +18 -0
  359. spm/spm_eeg_inv_vbecd_mom.py +40 -0
  360. spm/spm_eeg_inv_visu3D_api.py +20 -0
  361. spm/spm_eeg_invert.py +132 -0
  362. spm/spm_eeg_invert_EBoptimise.py +31 -0
  363. spm/spm_eeg_invert_bma.py +20 -0
  364. spm/spm_eeg_invert_classic.py +73 -0
  365. spm/spm_eeg_invert_classic_mix.py +28 -0
  366. spm/spm_eeg_invert_classic_volumetric.py +78 -0
  367. spm/spm_eeg_invert_display.py +22 -0
  368. spm/spm_eeg_invert_prepro.py +35 -0
  369. spm/spm_eeg_invert_setuppatches.py +28 -0
  370. spm/spm_eeg_invert_ui.py +26 -0
  371. spm/spm_eeg_invertiter.py +23 -0
  372. spm/spm_eeg_lapmtx.py +20 -0
  373. spm/spm_eeg_layout3D.py +16 -0
  374. spm/spm_eeg_lgainmat.py +19 -0
  375. spm/spm_eeg_load.py +22 -0
  376. spm/spm_eeg_locate_channels.py +29 -0
  377. spm/spm_eeg_mask.py +22 -0
  378. spm/spm_eeg_mask2channels.py +22 -0
  379. spm/spm_eeg_merge.py +68 -0
  380. spm/spm_eeg_meshnative2mni.py +19 -0
  381. spm/spm_eeg_modality_ui.py +24 -0
  382. spm/spm_eeg_montage.py +62 -0
  383. spm/spm_eeg_montage_ui.py +22 -0
  384. spm/spm_eeg_morlet.py +36 -0
  385. spm/spm_eeg_planarchannelset.py +18 -0
  386. spm/spm_eeg_plotScalpData.py +30 -0
  387. spm/spm_eeg_prep.py +27 -0
  388. spm/spm_eeg_prep_ui.py +16 -0
  389. spm/spm_eeg_project3D.py +16 -0
  390. spm/spm_eeg_read_bsa.py +18 -0
  391. spm/spm_eeg_reduce.py +35 -0
  392. spm/spm_eeg_reduce_cva.py +26 -0
  393. spm/spm_eeg_reduce_imagcsd.py +27 -0
  394. spm/spm_eeg_reduce_pca.py +26 -0
  395. spm/spm_eeg_reduce_pca_adapt.py +26 -0
  396. spm/spm_eeg_reduce_whiten.py +26 -0
  397. spm/spm_eeg_regressors.py +28 -0
  398. spm/spm_eeg_regressors_chandata.py +25 -0
  399. spm/spm_eeg_regressors_movement_ctf.py +25 -0
  400. spm/spm_eeg_regressors_tfphase.py +25 -0
  401. spm/spm_eeg_regressors_tfpower.py +25 -0
  402. spm/spm_eeg_remove_bad_trials.py +27 -0
  403. spm/spm_eeg_render.py +43 -0
  404. spm/spm_eeg_review.py +21 -0
  405. spm/spm_eeg_review_callbacks.py +14 -0
  406. spm/spm_eeg_review_switchDisplay.py +14 -0
  407. spm/spm_eeg_review_uis.py +14 -0
  408. spm/spm_eeg_robust_averaget.py +19 -0
  409. spm/spm_eeg_select_event_ui.py +15 -0
  410. spm/spm_eeg_simulate.py +29 -0
  411. spm/spm_eeg_simulate_frominv.py +22 -0
  412. spm/spm_eeg_smoothmesh_mm.py +18 -0
  413. spm/spm_eeg_spatial_confounds.py +21 -0
  414. spm/spm_eeg_specest_hilbert.py +33 -0
  415. spm/spm_eeg_specest_morlet.py +34 -0
  416. spm/spm_eeg_specest_mtmconvol.py +36 -0
  417. spm/spm_eeg_specest_mtmfft.py +33 -0
  418. spm/spm_eeg_spmft_chan_dictionary.py +15 -0
  419. spm/spm_eeg_tf.py +54 -0
  420. spm/spm_eeg_tf_rescale.py +37 -0
  421. spm/spm_eeg_wrap_dipfit_vbecd.py +24 -0
  422. spm/spm_eeg_wrap_momfit_vbecd.py +25 -0
  423. spm/spm_ekf.py +35 -0
  424. spm/spm_en.py +21 -0
  425. spm/spm_epharm.py +24 -0
  426. spm/spm_erode.py +40 -0
  427. spm/spm_est_V.py +19 -0
  428. spm/spm_est_non_sphericity.py +40 -0
  429. spm/spm_est_smoothness.py +63 -0
  430. spm/spm_existfile.py +24 -0
  431. spm/spm_expm.py +23 -0
  432. spm/spm_extract_files.py +16 -0
  433. spm/spm_extrapolate_def.py +21 -0
  434. spm/spm_fMRI_design.py +176 -0
  435. spm/spm_field.py +136 -0
  436. spm/spm_fieldindices.py +25 -0
  437. spm/spm_figure.py +55 -0
  438. spm/spm_file.py +64 -0
  439. spm/spm_file_ext.py +23 -0
  440. spm/spm_file_merge.py +28 -0
  441. spm/spm_file_split.py +19 -0
  442. spm/spm_fileparts.py +21 -0
  443. spm/spm_filter.py +36 -0
  444. spm/spm_find_pC.py +30 -0
  445. spm/spm_flip_analyze_images.py +19 -0
  446. spm/spm_fmin.py +34 -0
  447. spm/spm_fmri_concatenate.py +32 -0
  448. spm/spm_fmri_spm_ui.py +182 -0
  449. spm/spm_fn_reml.py +32 -0
  450. spm/spm_fp.py +35 -0
  451. spm/spm_fp_display_density.py +21 -0
  452. spm/spm_fp_display_nullclines.py +20 -0
  453. spm/spm_fp_fmin.py +25 -0
  454. spm/spm_fp_fun.py +25 -0
  455. spm/spm_fs_fmri_csd.py +23 -0
  456. spm/spm_funcheck.py +18 -0
  457. spm/spm_funfun.py +21 -0
  458. spm/spm_fx_fmri.py +44 -0
  459. spm/spm_fx_fmri_linear.py +40 -0
  460. spm/spm_fx_hdm.py +37 -0
  461. spm/spm_fx_lz.py +18 -0
  462. spm/spm_fx_poly.py +20 -0
  463. spm/spm_gamrnd.py +29 -0
  464. spm/spm_gen_fmri.py +40 -0
  465. spm/spm_getSPM.py +192 -0
  466. spm/spm_get_anatomical_layout.py +90 -0
  467. spm/spm_get_bbox.py +23 -0
  468. spm/spm_get_bf.py +39 -0
  469. spm/spm_get_closest_affine.py +34 -0
  470. spm/spm_get_data.py +23 -0
  471. spm/spm_get_dataset.py +19 -0
  472. spm/spm_get_defaults.py +29 -0
  473. spm/spm_get_lm.py +31 -0
  474. spm/spm_get_matdim.py +30 -0
  475. spm/spm_get_ons.py +48 -0
  476. spm/spm_get_space.py +18 -0
  477. spm/spm_get_vc.py +37 -0
  478. spm/spm_get_volumes.py +17 -0
  479. spm/spm_glass.py +31 -0
  480. spm/spm_global.py +24 -0
  481. spm/spm_gn_fmin.py +26 -0
  482. spm/spm_graph.py +34 -0
  483. spm/spm_graph_ui.py +78 -0
  484. spm/spm_grid.py +21 -0
  485. spm/spm_gx_fmri.py +25 -0
  486. spm/spm_gx_fmri_linear.py +25 -0
  487. spm/spm_gx_hdm.py +24 -0
  488. spm/spm_gx_state_fmri.py +26 -0
  489. spm/spm_hanning.py +17 -0
  490. spm/spm_hdm_priors.py +34 -0
  491. spm/spm_hdm_ui.py +25 -0
  492. spm/spm_help.py +66 -0
  493. spm/spm_hilbert.py +18 -0
  494. spm/spm_hist.py +17 -0
  495. spm/spm_hist2.py +29 -0
  496. spm/spm_hist_smooth.py +17 -0
  497. spm/spm_hrf.py +42 -0
  498. spm/spm_image.py +58 -0
  499. spm/spm_imatrix.py +20 -0
  500. spm/spm_imcalc.py +92 -0
  501. spm/spm_ind2sub.py +31 -0
  502. spm/spm_inline2func.py +15 -0
  503. spm/spm_input.py +181 -0
  504. spm/spm_int.py +65 -0
  505. spm/spm_int_B.py +69 -0
  506. spm/spm_int_D.py +67 -0
  507. spm/spm_int_E.py +68 -0
  508. spm/spm_int_J.py +71 -0
  509. spm/spm_int_L.py +70 -0
  510. spm/spm_int_ode.py +70 -0
  511. spm/spm_int_sde.py +71 -0
  512. spm/spm_interp.py +17 -0
  513. spm/spm_inv.py +22 -0
  514. spm/spm_invBcdf.py +60 -0
  515. spm/spm_invFcdf.py +71 -0
  516. spm/spm_invGcdf.py +64 -0
  517. spm/spm_invIcdf.py +57 -0
  518. spm/spm_invNcdf.py +72 -0
  519. spm/spm_invPcdf.py +56 -0
  520. spm/spm_invTcdf.py +74 -0
  521. spm/spm_invXcdf.py +56 -0
  522. spm/spm_inv_phi.py +17 -0
  523. spm/spm_inv_spd.py +20 -0
  524. spm/spm_ipharm.py +24 -0
  525. spm/spm_iwft.py +19 -0
  526. spm/spm_jobman.py +66 -0
  527. spm/spm_jsonread.py +28 -0
  528. spm/spm_jsonwrite.py +34 -0
  529. spm/spm_kernels.py +44 -0
  530. spm/spm_kl_dirichlet.py +23 -0
  531. spm/spm_kl_gamma.py +20 -0
  532. spm/spm_kl_normal.py +22 -0
  533. spm/spm_kl_normald.py +24 -0
  534. spm/spm_kl_wishart.py +21 -0
  535. spm/spm_kron.py +27 -0
  536. spm/spm_krutil.py +57 -0
  537. spm/spm_large_dcm_reduce.py +27 -0
  538. spm/spm_length.py +23 -0
  539. spm/spm_lg_gamma.py +23 -0
  540. spm/spm_list.py +124 -0
  541. spm/spm_load.py +21 -0
  542. spm/spm_load_priors8.py +22 -0
  543. spm/spm_log.py +15 -0
  544. spm/spm_log_evidence.py +39 -0
  545. spm/spm_log_evidence_reduce.py +34 -0
  546. spm/spm_logdet.py +20 -0
  547. spm/spm_lorenz_k.py +20 -0
  548. spm/spm_lotka_volterra.py +28 -0
  549. spm/spm_maff8.py +30 -0
  550. spm/spm_make_contrasts.py +36 -0
  551. spm/spm_marginal.py +20 -0
  552. spm/spm_mask.py +31 -0
  553. spm/spm_match_str.py +21 -0
  554. spm/spm_matrix.py +54 -0
  555. spm/spm_max.py +33 -0
  556. spm/spm_mb_ui.py +135 -0
  557. spm/spm_meanby.py +28 -0
  558. spm/spm_mesh.py +17 -0
  559. spm/spm_mesh_adjacency.py +18 -0
  560. spm/spm_mesh_area.py +25 -0
  561. spm/spm_mesh_borders.py +19 -0
  562. spm/spm_mesh_bounding_volume.py +22 -0
  563. spm/spm_mesh_calc.py +23 -0
  564. spm/spm_mesh_clusters.py +20 -0
  565. spm/spm_mesh_contour.py +35 -0
  566. spm/spm_mesh_cube.py +20 -0
  567. spm/spm_mesh_curvature.py +18 -0
  568. spm/spm_mesh_detect.py +17 -0
  569. spm/spm_mesh_dist.py +26 -0
  570. spm/spm_mesh_distmtx.py +21 -0
  571. spm/spm_mesh_edges.py +20 -0
  572. spm/spm_mesh_euler.py +26 -0
  573. spm/spm_mesh_geodesic.py +34 -0
  574. spm/spm_mesh_get_lm.py +20 -0
  575. spm/spm_mesh_inflate.py +20 -0
  576. spm/spm_mesh_inside.py +41 -0
  577. spm/spm_mesh_isoline.py +38 -0
  578. spm/spm_mesh_isosurface.py +23 -0
  579. spm/spm_mesh_join.py +21 -0
  580. spm/spm_mesh_label.py +22 -0
  581. spm/spm_mesh_laplacian.py +23 -0
  582. spm/spm_mesh_mass_matrix.py +17 -0
  583. spm/spm_mesh_max.py +27 -0
  584. spm/spm_mesh_neighbours.py +21 -0
  585. spm/spm_mesh_normals.py +20 -0
  586. spm/spm_mesh_polyhedron.py +22 -0
  587. spm/spm_mesh_project.py +26 -0
  588. spm/spm_mesh_ray_intersect.py +40 -0
  589. spm/spm_mesh_ray_triangle.py +32 -0
  590. spm/spm_mesh_reduce.py +35 -0
  591. spm/spm_mesh_refine.py +25 -0
  592. spm/spm_mesh_render.py +49 -0
  593. spm/spm_mesh_resels.py +31 -0
  594. spm/spm_mesh_sdf.py +43 -0
  595. spm/spm_mesh_select.py +20 -0
  596. spm/spm_mesh_smooth.py +22 -0
  597. spm/spm_mesh_sphere.py +22 -0
  598. spm/spm_mesh_split.py +20 -0
  599. spm/spm_mesh_to_grid.py +20 -0
  600. spm/spm_mesh_transform.py +18 -0
  601. spm/spm_mesh_utils.py +26 -0
  602. spm/spm_mesh_volume.py +18 -0
  603. spm/spm_mesh_voxelise.py +30 -0
  604. spm/spm_mfx.py +88 -0
  605. spm/spm_minmax.py +23 -0
  606. spm/spm_mip.py +46 -0
  607. spm/spm_mip_ui.py +79 -0
  608. spm/spm_mkdir.py +19 -0
  609. spm/spm_mldivide.py +25 -0
  610. spm/spm_mnc2nifti.py +26 -0
  611. spm/spm_morlet.py +25 -0
  612. spm/spm_morlet_conv.py +26 -0
  613. spm/spm_mrdivide.py +25 -0
  614. spm/spm_mrf.py +54 -0
  615. spm/spm_mtx_cos.py +19 -0
  616. spm/spm_multrnd.py +20 -0
  617. spm/spm_mvNpdf.py +34 -0
  618. spm/spm_mvb.py +79 -0
  619. spm/spm_mvb_G.py +48 -0
  620. spm/spm_mvb_R2.py +18 -0
  621. spm/spm_mvb_U.py +29 -0
  622. spm/spm_mvb_bmc.py +20 -0
  623. spm/spm_mvb_cvk.py +26 -0
  624. spm/spm_mvb_cvk2.py +27 -0
  625. spm/spm_mvb_cvk_display.py +16 -0
  626. spm/spm_mvb_display.py +16 -0
  627. spm/spm_mvb_estimate.py +77 -0
  628. spm/spm_mvb_p.py +25 -0
  629. spm/spm_mvb_ui.py +87 -0
  630. spm/spm_nCr.py +70 -0
  631. spm/spm_ncFcdf.py +22 -0
  632. spm/spm_ncFpdf.py +27 -0
  633. spm/spm_ncTcdf.py +26 -0
  634. spm/spm_ncTpdf.py +27 -0
  635. spm/spm_ndgrid.py +21 -0
  636. spm/spm_ness.py +43 -0
  637. spm/spm_ness_GN.py +37 -0
  638. spm/spm_ness_J.py +15 -0
  639. spm/spm_ness_Lap.py +37 -0
  640. spm/spm_ness_N2Sp.py +18 -0
  641. spm/spm_ness_Sp2N.py +22 -0
  642. spm/spm_ness_Sp2p.py +21 -0
  643. spm/spm_ness_U.py +39 -0
  644. spm/spm_ness_cond.py +25 -0
  645. spm/spm_ness_flows.py +21 -0
  646. spm/spm_ness_hd.py +37 -0
  647. spm/spm_ness_m2S.py +20 -0
  648. spm/spm_ness_p2Sp.py +21 -0
  649. spm/spm_nlsi.py +99 -0
  650. spm/spm_nlsi_AI.py +94 -0
  651. spm/spm_nlsi_GN.py +106 -0
  652. spm/spm_nlsi_GN_H.py +69 -0
  653. spm/spm_nlsi_LS.py +95 -0
  654. spm/spm_nlsi_N.py +94 -0
  655. spm/spm_nlsi_Newton.py +56 -0
  656. spm/spm_non_sphericity.py +67 -0
  657. spm/spm_normrnd.py +21 -0
  658. spm/spm_opm_amm.py +28 -0
  659. spm/spm_orientations.py +57 -0
  660. spm/spm_orth.py +25 -0
  661. spm/spm_orthpoly.py +21 -0
  662. spm/spm_orthviews.py +161 -0
  663. spm/spm_padarray.py +24 -0
  664. spm/spm_parrec2nifti.py +21 -0
  665. spm/spm_pca_get_transforms.py +12 -0
  666. spm/spm_pca_project_velocity.py +18 -0
  667. spm/spm_pca_sample_brains.py +24 -0
  668. spm/spm_pca_sample_deformation.py +17 -0
  669. spm/spm_pca_transform_mesh.py +23 -0
  670. spm/spm_pca_transform_volume.py +20 -0
  671. spm/spm_pca_warps.py +26 -0
  672. spm/spm_peb_ppi.py +57 -0
  673. spm/spm_percentile.py +26 -0
  674. spm/spm_perm_mtx.py +20 -0
  675. spm/spm_permute_kron.py +18 -0
  676. spm/spm_pf.py +37 -0
  677. spm/spm_phase_shuffle.py +17 -0
  678. spm/spm_phi.py +17 -0
  679. spm/spm_phi_dot.py +16 -0
  680. spm/spm_pinv.py +19 -0
  681. spm/spm_platform.py +51 -0
  682. spm/spm_plot_ci.py +37 -0
  683. spm/spm_plot_convergence.py +22 -0
  684. spm/spm_polymtx.py +29 -0
  685. spm/spm_powell.py +28 -0
  686. spm/spm_preproc.py +27 -0
  687. spm/spm_preproc8.py +82 -0
  688. spm/spm_preproc_run.py +38 -0
  689. spm/spm_preproc_write8.py +15 -0
  690. spm/spm_print.py +22 -0
  691. spm/spm_progress_bar.py +30 -0
  692. spm/spm_project.py +31 -0
  693. spm/spm_psi.py +21 -0
  694. spm/spm_rand_mar.py +20 -0
  695. spm/spm_rand_power_law.py +24 -0
  696. spm/spm_read_netcdf.py +19 -0
  697. spm/spm_read_vols.py +25 -0
  698. spm/spm_realign.py +96 -0
  699. spm/spm_regions.py +60 -0
  700. spm/spm_reml.py +47 -0
  701. spm/spm_reml_A.py +45 -0
  702. spm/spm_reml_ancova.py +41 -0
  703. spm/spm_reml_sc.py +54 -0
  704. spm/spm_render.py +43 -0
  705. spm/spm_render_vol.py +39 -0
  706. spm/spm_reorder_contrasts.py +19 -0
  707. spm/spm_resels.py +35 -0
  708. spm/spm_resels_vol.py +31 -0
  709. spm/spm_reslice.py +69 -0
  710. spm/spm_results_nidm.py +33 -0
  711. spm/spm_results_ui.py +134 -0
  712. spm/spm_rmpath.py +27 -0
  713. spm/spm_robust_average.py +20 -0
  714. spm/spm_robust_glm.py +28 -0
  715. spm/spm_s2csd.py +20 -0
  716. spm/spm_sample_priors8.py +25 -0
  717. spm/spm_sample_vol.py +38 -0
  718. spm/spm_save.py +18 -0
  719. spm/spm_sde_dx.py +39 -0
  720. spm/spm_sdot.py +26 -0
  721. spm/spm_searchlight.py +44 -0
  722. spm/spm_sections.py +24 -0
  723. spm/spm_select.py +71 -0
  724. spm/spm_sepmul3d.py +27 -0
  725. spm/spm_shp_get_model.py +21 -0
  726. spm/spm_shp_get_transforms.py +32 -0
  727. spm/spm_shp_install.py +16 -0
  728. spm/spm_shp_project_velocity.py +24 -0
  729. spm/spm_shp_sample_brains.py +43 -0
  730. spm/spm_shp_sample_deformation.py +27 -0
  731. spm/spm_shp_transform_mesh.py +30 -0
  732. spm/spm_shp_transform_volume.py +26 -0
  733. spm/spm_shp_warps.py +27 -0
  734. spm/spm_sixel.py +27 -0
  735. spm/spm_slice_timing.py +99 -0
  736. spm/spm_slice_vol.py +35 -0
  737. spm/spm_slm.py +24 -0
  738. spm/spm_smohist.py +27 -0
  739. spm/spm_smooth.py +32 -0
  740. spm/spm_smoothkern.py +35 -0
  741. spm/spm_smoothto8bit.py +19 -0
  742. spm/spm_softmax.py +23 -0
  743. spm/spm_soreduce.py +42 -0
  744. spm/spm_sp.py +189 -0
  745. spm/spm_sp_reml.py +44 -0
  746. spm/spm_sparse_regression.py +33 -0
  747. spm/spm_speye.py +20 -0
  748. spm/spm_spm.py +278 -0
  749. spm/spm_spm_Bayes.py +75 -0
  750. spm/spm_spm_Bayes_CY.py +23 -0
  751. spm/spm_spm_Bayes_specify.py +30 -0
  752. spm/spm_sptop.py +30 -0
  753. spm/spm_spy.py +18 -0
  754. spm/spm_sqrtm.py +19 -0
  755. spm/spm_squeeze.py +15 -0
  756. spm/spm_ssm2s.py +24 -0
  757. spm/spm_standalone.py +21 -0
  758. spm/spm_str_manip.py +58 -0
  759. spm/spm_subfun.py +20 -0
  760. spm/spm_sum.py +17 -0
  761. spm/spm_summarise.py +35 -0
  762. spm/spm_surf.py +63 -0
  763. spm/spm_svd.py +22 -0
  764. spm/spm_swarp.py +24 -0
  765. spm/spm_t2z.py +63 -0
  766. spm/spm_tests.py +26 -0
  767. spm/spm_timeseries_resample.py +23 -0
  768. spm/spm_trace.py +17 -0
  769. spm/spm_transverse.py +45 -0
  770. spm/spm_type.py +34 -0
  771. spm/spm_u.py +29 -0
  772. spm/spm_uc.py +33 -0
  773. spm/spm_uc_Bonf.py +32 -0
  774. spm/spm_uc_FDR.py +89 -0
  775. spm/spm_uc_RF.py +32 -0
  776. spm/spm_uc_clusterFDR.py +47 -0
  777. spm/spm_uc_peakFDR.py +45 -0
  778. spm/spm_uitab.py +35 -0
  779. spm/spm_uncat.py +21 -0
  780. spm/spm_unlink.py +17 -0
  781. spm/spm_unvec.py +22 -0
  782. spm/spm_update.py +31 -0
  783. spm/spm_uw_apply.py +128 -0
  784. spm/spm_uw_estimate.py +90 -0
  785. spm/spm_uw_get_image_def.py +46 -0
  786. spm/spm_uw_show.py +20 -0
  787. spm/spm_vb_F.py +25 -0
  788. spm/spm_vb_Fn.py +27 -0
  789. spm/spm_vb_a.py +18 -0
  790. spm/spm_vb_adjacency.py +22 -0
  791. spm/spm_vb_alpha.py +18 -0
  792. spm/spm_vb_beta.py +18 -0
  793. spm/spm_vb_contrasts.py +23 -0
  794. spm/spm_vb_edgeweights.py +20 -0
  795. spm/spm_vb_gamma.py +18 -0
  796. spm/spm_vb_get_Ab.py +24 -0
  797. spm/spm_vb_get_Gn.py +19 -0
  798. spm/spm_vb_get_R.py +19 -0
  799. spm/spm_vb_glmar.py +85 -0
  800. spm/spm_vb_graphcut.py +35 -0
  801. spm/spm_vb_incidence.py +23 -0
  802. spm/spm_vb_init_block.py +18 -0
  803. spm/spm_vb_lambda.py +18 -0
  804. spm/spm_vb_logbf.py +20 -0
  805. spm/spm_vb_models.py +22 -0
  806. spm/spm_vb_neighbors.py +27 -0
  807. spm/spm_vb_ppm_anova.py +39 -0
  808. spm/spm_vb_regionF.py +34 -0
  809. spm/spm_vb_robust.py +26 -0
  810. spm/spm_vb_roi_anova.py +28 -0
  811. spm/spm_vb_roi_basis.py +57 -0
  812. spm/spm_vb_set_priors.py +41 -0
  813. spm/spm_vb_spatial_precision.py +22 -0
  814. spm/spm_vb_taylor_R.py +20 -0
  815. spm/spm_vb_w.py +18 -0
  816. spm/spm_vec.py +23 -0
  817. spm/spm_vecfun.py +20 -0
  818. spm/spm_vol.py +41 -0
  819. spm/spm_vol_nifti.py +19 -0
  820. spm/spm_voronoi.py +29 -0
  821. spm/spm_wft.py +19 -0
  822. spm/spm_write_filtered.py +34 -0
  823. spm/spm_write_plane.py +24 -0
  824. spm/spm_write_residuals.py +20 -0
  825. spm/spm_write_vol.py +22 -0
  826. spm/spm_z2p.py +26 -0
  827. spm/spm_zeros.py +16 -0
  828. spm/xmltree.py +619 -0
  829. spm_python-25.1a1.dev1.dist-info/AUTHORS.txt +53 -0
  830. spm_python-25.1a1.dev1.dist-info/LICENCE +339 -0
  831. spm_python-25.1a1.dev1.dist-info/METADATA +151 -0
  832. spm_python-25.1a1.dev1.dist-info/RECORD +834 -0
  833. spm_python-25.1a1.dev1.dist-info/WHEEL +5 -0
  834. spm_python-25.1a1.dev1.dist-info/top_level.txt +1 -0
@@ -0,0 +1,33 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_results_nidm(*args, **kwargs):
5
+ """
6
+ Export SPM stats results using the Neuroimaging Data Model (NIDM)
7
+ FORMAT [nidmfile, prov] = spm_results_nidm(SPM,xSPM,TabDat,opts)
8
+ SPM - structure containing analysis details (see spm_spm.m)
9
+ xSPM - structure containing inference details (see spm_getSPM.m)
10
+ TabDat - structure containing results details (see spm_list.m)
11
+ opts - structure containing extra information about:
12
+ .group - subject/group(s) under study
13
+ .mod - data modality
14
+ .space - reference space
15
+
16
+ nidmfile - output NIDM zip archive filename
17
+ prov - provenance object (see spm_provenance.m)
18
+ __________________________________________________________________________
19
+ References:
20
+
21
+ Neuroimaging Data Model (NIDM):
22
+ http://nidm.nidash.org/
23
+
24
+ PROV-DM: The PROV Data Model:
25
+ http://www.w3.org/TR/prov-dm/
26
+ __________________________________________________________________________
27
+
28
+
29
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_results_nidm.m )
30
+
31
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
32
+ """
33
+ return Runtime.call("spm_results_nidm", *args, **kwargs)
spm/spm_results_ui.py ADDED
@@ -0,0 +1,134 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_results_ui(*args, **kwargs):
5
+ """
6
+ User interface for SPM/PPM results: Display and analysis of regional effects
7
+ FORMAT [hReg,xSPM,SPM] = spm_results_ui('Setup',[xSPM])
8
+
9
+ hReg - handle of MIP XYZ registry object
10
+ (see spm_XYZreg.m for details)
11
+ xSPM - structure containing specific SPM, distribution & filtering details
12
+ (see spm_getSPM.m for contents)
13
+ SPM - SPM structure containing generic parameters
14
+ (see spm_spm.m for contents)
15
+
16
+ NB: Results section GUI CallBacks use these data structures by name,
17
+ which therefore *must* be assigned to the correctly named variables.
18
+ __________________________________________________________________________
19
+
20
+ The SPM results section is for the interactive exploration and
21
+ characterisation of the results of a statistical analysis.
22
+
23
+ The user is prompted to select a SPM{T} or SPM{F}, that is thresholded at
24
+ user specified levels. The specification of the contrasts to use and the
25
+ height and size thresholds are described in spm_getSPM.m. The resulting
26
+ SPM is then displayed in the Graphics window as a maximum intensity
27
+ projection, alongside the design matrix and contrasts employed.
28
+
29
+ The cursors in the MIP can be moved (dragged) to select a particular
30
+ voxel. The three mouse buttons give different drag and drop behaviour:
31
+ Button 1 - point & drop; Button 2 - "dynamic" drag & drop with
32
+ coordinate & SPM value updating; Button 3 - "magnetic" drag & drop,
33
+ where the cursor jumps to the nearest suprathreshold voxel in the MIP,
34
+ and shows the value there.
35
+ See spm_mip_ui.m, the MIP GUI handling function for further details.
36
+
37
+ The design matrix and contrast pictures are "surfable": Click and drag
38
+ over the images to report associated data. Clicking with different
39
+ buttons produces different results. Double-clicking extracts the
40
+ underlying data into the base workspace.
41
+ See spm_DesRep.m for further details.
42
+
43
+ The current voxel specifies the voxel, suprathreshold cluster, or
44
+ orthogonal planes (planes passing through that voxel) for subsequent
45
+ localised utilities.
46
+
47
+ A control panel in the Interactive window enables interactive exploration
48
+ of the results.
49
+
50
+ p-values buttons:
51
+ (i) volume - Tabulates p-values and statistics for entire volume.
52
+ - see spm_list.m
53
+ (ii) cluster - Tabulates p-values and statistics for nearest cluster.
54
+ - Note that the cursor will jump to the nearest
55
+ suprathreshold voxel, if it is not already at a
56
+ location with suprathreshold statistic.
57
+ - see spm_list.m
58
+ (iii) S.V.C - Small Volume Correction:
59
+ Tabulates p-values corrected for a small specified
60
+ volume of interest. (Tabulation by spm_list.m)
61
+ - see spm_VOI.m
62
+
63
+ Data extraction buttons:
64
+ Eigenvariate/CVA
65
+ - Extracts the principal eigenvariate for small volumes
66
+ of interest; or CVA of data within a specified volume
67
+ - Data can be adjusted or not for eigenvariate summaries
68
+ - If temporal filtering was specified (fMRI), then it is
69
+ the filtered data that is returned.
70
+ - Choose a VOI of radius 0 to extract the (filtered &)
71
+ adjusted data for a single voxel. Note that this vector
72
+ will be scaled to have a 2-norm of 1. (See spm_regions.m
73
+ for further details.)
74
+ - The plot button also returns fitted and adjusted
75
+ (after any filtering) data for the voxel being plotted.)
76
+ - Note that the cursor will jump to the nearest voxel for
77
+ which raw data was saved.
78
+ - see spm_regions.m
79
+
80
+ Visualisation buttons:
81
+ (i) plot - Graphs of adjusted and fitted activity against
82
+ various ordinates.
83
+ - Note that the cursor will jump to the nearest
84
+ suprathreshold voxel, if it is not already at a
85
+ location with suprathreshold statistic.
86
+ - Additionally, returns fitted and adjusted data to the
87
+ MATLAB base workspace.
88
+ - see spm_graph.m
89
+ (ii) overlays - Popup menu: Overlays of filtered SPM on a structural image
90
+ - slices - Slices of the thresholded statistic image overlaid
91
+ on a secondary image chosen by the user. Three
92
+ transverse slices are shown, being those at the
93
+ level of the cursor in the z-axis and the two
94
+ adjacent to it. - see spm_transverse.m
95
+ - sections - Orthogonal sections of the thresholded statistic
96
+ image overlaid on a secondary image chosen by the user.
97
+ The sections are through the cursor position.
98
+ - see spm_sections.m
99
+ - render - Render blobs on previously extracted cortical surface
100
+ - see spm_render.m
101
+ (iii) save - Write out thresholded SPM as image
102
+ - see spm_write_filtered.m
103
+
104
+ The current cursor location can be set by editing the coordinate widgets
105
+ at the bottom of the Interactive window. (Note that many of the results
106
+ section facilities are "linked" and can update coordinates. E.g.
107
+ clicking on the coordinates in a p-value listing jumps to that location.)
108
+
109
+ Graphics appear in the bottom half of the Graphics window, additional
110
+ controls and questions appearing in the Interactive window.
111
+
112
+ ----------------
113
+
114
+ The MIP uses a template outline in MNI space. Consequently for the
115
+ results section to display properly the input images to the statistics
116
+ section should be in MNI space.
117
+
118
+ Similarly, secondary images should be aligned with the input images used
119
+ for the statistical analysis.
120
+
121
+ ----------------
122
+
123
+ In addition to setting up the results section, spm_results_ui.m sets
124
+ up the results section GUI and services the CallBacks. FORMAT
125
+ specifications for embedded CallBack functions are given in the main
126
+ body of the code.
127
+ __________________________________________________________________________
128
+
129
+
130
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_results_ui.m )
131
+
132
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
133
+ """
134
+ return Runtime.call("spm_results_ui", *args, **kwargs)
spm/spm_rmpath.py ADDED
@@ -0,0 +1,27 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_rmpath(*args, **kwargs):
5
+ """
6
+ Recursively remove SPM paths from the MATLAB path
7
+ SPM_RMPATH checks if the file spm.m is found and removes the
8
+ path to that file and any subdirectories below it from the MATLAB
9
+ path.
10
+
11
+ P = SPM_RMPATH performs the same function as above and returns the
12
+ cleaned path string in P.
13
+
14
+ SPM_RMPATH(D) strips the path string D from the MATLAB path.
15
+
16
+ P = SPM_RMPATH(D) strips the path string D from the MATLAB path and
17
+ returns the cleaned path string in P.
18
+
19
+ See also PATH, ADDPATH, RMPATH, GENPATH, PATHTOOL, SAVEPATH.
20
+ __________________________________________________________________________
21
+
22
+
23
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_rmpath.m )
24
+
25
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
26
+ """
27
+ return Runtime.call("spm_rmpath", *args, **kwargs)
@@ -0,0 +1,20 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_robust_average(*args, **kwargs):
5
+ """
6
+ Apply robust averaging routine to X sets
7
+ FORMAT [Y,W] = spm_robust_averaget(X, dim, ks)
8
+ X - data matrix to be averaged
9
+ dim - the dimension along which the function will work
10
+ ks - offset of the weighting function (default: 3)
11
+
12
+ W - estimated weights
13
+ __________________________________________________________________________
14
+
15
+
16
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_robust_average.m )
17
+
18
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
19
+ """
20
+ return Runtime.call("spm_robust_average", *args, **kwargs)
spm/spm_robust_glm.py ADDED
@@ -0,0 +1,28 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_robust_glm(*args, **kwargs):
5
+ """
6
+ Apply robust GLM
7
+ FORMAT [B, W] = spm_robust_glm(Y, X, dim, ks)
8
+ Y - data matrix
9
+ X - design matrix
10
+ dim - the dimension along which the function will work
11
+ ks - offset of the weighting function (default: 3)
12
+
13
+ OUTPUT:
14
+ B - parameter estimates
15
+ W - estimated weights
16
+
17
+ Implementation of:
18
+ Wager TD, Keller MC, Lacey SC, Jonides J.
19
+ Increased sensitivity in neuroimaging analyses using robust regression.
20
+ Neuroimage. 2005 May 15;26(1):99-113
21
+ __________________________________________________________________________
22
+
23
+
24
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_robust_glm.m )
25
+
26
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
27
+ """
28
+ return Runtime.call("spm_robust_glm", *args, **kwargs)
spm/spm_s2csd.py ADDED
@@ -0,0 +1,20 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_s2csd(*args, **kwargs):
5
+ """
6
+ Convert eigenspectrum to cross spectral density
7
+ FORMAT [csd,Hz] = spm_s2csd(s,Hz)
8
+
9
+ s (m x 1} - eigenspectrum
10
+ Hz (n x 1) - vector of frequencies (Hz)
11
+
12
+ csd (n,m) - spectral density (of modes)
13
+ __________________________________________________________________________
14
+
15
+
16
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_s2csd.m )
17
+
18
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
19
+ """
20
+ return Runtime.call("spm_s2csd", *args, **kwargs)
@@ -0,0 +1,25 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sample_priors8(*args, **kwargs):
5
+ """
6
+ Sample prior probability maps
7
+ FORMAT [s,ds1,ds2,ds3] = spm_sample_priors8(tpm,x1,x2,x3)
8
+ b - a cell array containing the tissue probability
9
+ data (see spm_load_priors)
10
+ x1,x2,x3 - coordinates to sample
11
+ s - sampled values
12
+ ds1,ds2,ds3 - spatial derivatives of sampled values
13
+
14
+ This function is intended to be used in conjunction with spm_load_priors.
15
+ V = spm_vol(P);
16
+ T = spm_load_priors(V);
17
+ B = spm_sample_priors(T,X,Y,Z);
18
+ __________________________________________________________________________
19
+
20
+
21
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sample_priors8.m )
22
+
23
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
24
+ """
25
+ return Runtime.call("spm_sample_priors8", *args, **kwargs)
spm/spm_sample_vol.py ADDED
@@ -0,0 +1,38 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sample_vol(*args, **kwargs):
5
+ """
6
+ Return voxel values from an image volume - a compiled routine
7
+ FORMAT X = spm_sample_vol(V,x,y,z,hold)
8
+ V - spm_vol structure
9
+ x - matrix of x coordinates {voxels}
10
+ y - matrix of y coordinates {voxels}
11
+ z - matrix of z coordinates {voxels}
12
+ hold - interpolation method for the resampling:
13
+ 0 : Zero-order hold (nearest neighbour)
14
+ 1 : First-order hold (trilinear interpolation)
15
+ 2->127 : Higher order Lagrange (polynomial) interpolation
16
+ using different holds (second-order upwards)
17
+ -127 - -1 : Different orders of sinc interpolation
18
+
19
+ X - output image
20
+
21
+ FORMAT [X,dX,dY,dZ] = spm_sample_vol(V,x,y,z,hold)
22
+ Similar to above, except that the derivatives in the three orthogonal
23
+ directions are also returned.
24
+ __________________________________________________________________________
25
+
26
+ spm_sample_vol returns the voxel values from an image volume indicated
27
+ by V at coordinates x,y,z. Values from coordinates outside the image
28
+ are set to zero. x, y and z must be matrices of the same dimensions.
29
+
30
+ See also: spm_vol.m, spm_slice_vol.m
31
+ __________________________________________________________________________
32
+
33
+
34
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sample_vol.m )
35
+
36
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
37
+ """
38
+ return Runtime.call("spm_sample_vol", *args, **kwargs)
spm/spm_save.py ADDED
@@ -0,0 +1,18 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_save(*args, **kwargs):
5
+ """
6
+ Save text and numeric data to file
7
+ FORMAT spm_save(f,var,opts,...)
8
+ f - filename (can be gzipped) {csv,tsv,json,txt,mat,npy}
9
+ var - data array or structure
10
+ opts - optional inputs to be passed on to lower level function
11
+ __________________________________________________________________________
12
+
13
+
14
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_save.m )
15
+
16
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
17
+ """
18
+ return Runtime.call("spm_save", *args, **kwargs, nargout=0)
spm/spm_sde_dx.py ADDED
@@ -0,0 +1,39 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sde_dx(*args, **kwargs):
5
+ """
6
+ Return dx(t) = (expm(dfdx*t) - I)*inv(dfdx)*f + w for SDEs
7
+ FORMAT [dx] = spm_sde_dx(dfdx,dfdw,f,t)
8
+ dfdx = df/dx - x: states
9
+ dfdw = df/dw - w: i.i.d. Weiner process
10
+ f = dx/dt
11
+ t = integration time: (default t = 1);
12
+
13
+ dx = x(t) - x(0)
14
+ --------------------------------------------------------------------------
15
+ Integration of stochastic differential equations using local linearization.
16
+ This scheme accommodates nonlinearities in the state equation by using a
17
+ functional of f(x) = dx/dt. This uses the equality
18
+
19
+ expm([0 0]*t) = expm(dfdx*t) - I)*inv(dfdx)*f
20
+ [f dfdx]
21
+
22
+ When t -> Inf this reduces to
23
+
24
+ dx(t) = -inv(dfdx)*f
25
+
26
+ for the SDE: dx = dfdx*x*dt + sqrt(2)*dfdw*dw
27
+
28
+ where w is a standard Wiener process. Unstable modes are removed using
29
+ the systems eigenmodes.
30
+
31
+ see also spm_dx
32
+ __________________________________________________________________________
33
+
34
+
35
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sde_dx.m )
36
+
37
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
38
+ """
39
+ return Runtime.call("spm_sde_dx", *args, **kwargs)
spm/spm_sdot.py ADDED
@@ -0,0 +1,26 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sdot(*args, **kwargs):
5
+ """
6
+ Sparse multidimensional dot (inner) product
7
+ FORMAT [Y] = spm_sdot(X,x,[DIM])
8
+
9
+ X - numeric array
10
+ x - cell array of numeric vectors
11
+ DIM - dimension to omit (assumes ndims(X) = numel(x))
12
+
13
+ Y - inner product obtained by summing the products of X and x along DIM
14
+
15
+ If DIM is not specified the leading dimensions of X are omitted. This
16
+ routine assumes X is sparse
17
+
18
+ See also: spm_dot, spm_cross
19
+ __________________________________________________________________________
20
+
21
+
22
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sdot.m )
23
+
24
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
25
+ """
26
+ return Runtime.call("spm_sdot", *args, **kwargs)
spm/spm_searchlight.py ADDED
@@ -0,0 +1,44 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_searchlight(*args, **kwargs):
5
+ """
6
+ Local mass-multivariate (c.f., searchlight) facility
7
+ FORMAT R = spm_searchlight(SPM,searchopt,fun,varargin)
8
+ SPM - structure with fields:
9
+ .xY.VY - filenames char array or spm_vol struct array of images
10
+ .VM - filename or spm_vol structure to a mask (binary) image
11
+ Mask image can have any orientation, voxel size or data type.
12
+ It is interpolated using nearest neighbour interpolation to
13
+ the voxel locations of the data.
14
+ If empty, all voxels are used.
15
+ searchopt - searchlight options using VOI structure (xY) from spm_ROI
16
+ .def - searchlight definition {['sphere'] 'box'}
17
+ .spec - searchlight parameters [sphere radius {mm}]
18
+ fun - function handle to a function that takes three input arguments:
19
+ a [n x v] matrix (nb images x nb voxels within searchlight)
20
+ a [3 x v] matrix of voxels location within searchlight {vox}
21
+ a list of parameters provided in varargin
22
+ and returns a vector value [1 x N]
23
+ varargin - list of parameters sent to fun
24
+
25
+ R - a [N x 1] cell array with each output (fun nargout) reshaped
26
+ to a volume or directly a volume if N == 1
27
+ Values outside the mask are attributed NaN.
28
+ __________________________________________________________________________
29
+
30
+ References:
31
+
32
+ [1] Adaptive Analysis of fMRI Data. Friman O, Borga M, Lundberg P and
33
+ Knutsson H. (2003) NeuroImage 19(3):837-845.
34
+
35
+ [2] Information-based functional brain mapping. Kriegeskorte N, Goebel R,
36
+ Bandettini P. (2006) PNAS 103: 3863-3868.
37
+ __________________________________________________________________________
38
+
39
+
40
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_searchlight.m )
41
+
42
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
43
+ """
44
+ return Runtime.call("spm_searchlight", *args, **kwargs)
spm/spm_sections.py ADDED
@@ -0,0 +1,24 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sections(*args, **kwargs):
5
+ """
6
+ Rendering of regional effects [SPM{.}] on orthogonal sections
7
+ FORMAT spm_sections(xSPM,hReg,img)
8
+
9
+ xSPM - structure containing details of excursion set (see spm_getSPM)
10
+ hReg - handle of MIP register
11
+ img - filename of background image
12
+ __________________________________________________________________________
13
+
14
+ spm_sections is called by spm_results_ui and uses variable img to
15
+ create three orthogonal sections through a background image.
16
+ Regional foci from the selected xSPM are rendered on this image.
17
+ __________________________________________________________________________
18
+
19
+
20
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sections.m )
21
+
22
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
23
+ """
24
+ return Runtime.call("spm_sections", *args, **kwargs, nargout=0)
spm/spm_select.py ADDED
@@ -0,0 +1,71 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_select(*args, **kwargs):
5
+ """
6
+ File selector
7
+ FORMAT [t,sts] = spm_select(n,typ,mesg,sel,wd,filt,frames)
8
+ n - number of files [Default: Inf]
9
+ A single value or a range. e.g.
10
+ 1 - select one file
11
+ Inf - select any number of files
12
+ [1 Inf] - select 1 to Inf files
13
+ [0 1] - select 0 or 1 files
14
+ [10 12] - select from 10 to 12 files
15
+ typ - file type [Default: 'any']
16
+ 'any' - all files
17
+ 'image' - Image files (".img" and ".nii")
18
+ Note that it gives the option to select individuals
19
+ volumes of the images.
20
+ 'mesh' - Surface mesh files (".gii")
21
+ 'xml' - XML files
22
+ 'mat' - MATLAB .mat files or .txt files (assumed to contain
23
+ ASCII representation of a 2D-numeric array)
24
+ 'batch' - SPM batch files (.m or .mat)
25
+ 'dir' - select a directory
26
+ Other strings act as a filter to regexp. This means that
27
+ e.g. DCM*.mat files should have a typ of '^DCM.*\.mat$'
28
+ mesg - a prompt [Default: 'Select files...']
29
+ sel - list of already selected files [Default: {}]
30
+ wd - directory to start off in [Default: pwd]
31
+ filt - value for user-editable filter [Default: '.*']
32
+ frames - image frame numbers to include [Default: '1']
33
+
34
+ t - selected files
35
+ sts - status (1 means OK, 0 means window quit)
36
+
37
+ FORMAT [files,dirs] = spm_select('List',direc,filt)
38
+ Return files matching the filter 'filt' and directories within 'direc'
39
+ direc - directory to search [Default: pwd]
40
+ filt - filter to select files with regexp, e.g. '^w.*\.img$' [Default: '.*']
41
+
42
+ files - files matching 'filt' in directory 'direc'
43
+ dirs - subdirectories of 'direc'
44
+
45
+ FORMAT [files,dirs] = spm_select('ExtList',direc,filt,frames)
46
+ As above, but for selecting frames of 4D NIfTI files
47
+ frames - vector of frames to select (defaults to Inf, if not specified).
48
+ If the frame number is Inf, all frames for the matching images
49
+ are listed.
50
+
51
+ FORMAT [files,dirs] = spm_select('FPList',direc,filt)
52
+ FORMAT [files,dirs] = spm_select('ExtFPList',direc,filt,frames)
53
+ As above, but return files with full paths (i.e. prefixes 'direc' to each)
54
+
55
+ FORMAT [files,dirs] = spm_select('FPListRec',direc,filt)
56
+ FORMAT [files,dirs] = spm_select('ExtFPListRec',direc,filt,frames)
57
+ As above, but return files with full paths (i.e. prefixes 'direc' to each)
58
+ and search through sub directories recursively.
59
+
60
+ FORMAT [dirs] = spm_select('List',direc,'dir',filt)
61
+ FORMAT [dirs] = spm_select('FPList',direc,'dir',filt)
62
+ FORMAT [dirs] = spm_select('FPListRec',direc,'dir',filt)
63
+ Return directory names matching filter 'filt' within 'direc'
64
+ __________________________________________________________________________
65
+
66
+
67
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_select.m )
68
+
69
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
70
+ """
71
+ return Runtime.call("spm_select", *args, **kwargs)
spm/spm_sepmul3d.py ADDED
@@ -0,0 +1,27 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_sepmul3d(*args, **kwargs):
5
+ """
6
+ Compute t = kron(B3,kron(B2,B1))*T(:)
7
+
8
+ FORMAT t = spm_sepmul3d(B1,B2,B3,T)
9
+ B1 - x-dim basis functions [nx kx]
10
+ B2 - y-dim basis functions [ny ky]
11
+ B3 - z-dim basis functions [nz kz]
12
+ T - parameters encoding of the field [kx ky kz]
13
+ t - Reconstructed field [nx ny nz]
14
+
15
+ If T is a vector, then so is the output
16
+
17
+ Note that DCT basis functions are usually used,
18
+ but other forms are available. For example,
19
+ sparse B-spline basis functions could be used.
20
+ __________________________________________________________________________
21
+
22
+
23
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_sepmul3d.m )
24
+
25
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
26
+ """
27
+ return Runtime.call("spm_sepmul3d", *args, **kwargs)
@@ -0,0 +1,21 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_shp_get_model(*args, **kwargs):
5
+ """
6
+ Get the path to a Shape PCA model file, install/download if needed.
7
+
8
+ FORMAT path = spm_get_model(name)
9
+
10
+ name - Model variable to return
11
+ {'subspace_scaled', 'model_variables', 'Template_{01234}'}
12
+ dartadir - Data directory [spm('Dir')/tpl/shp]
13
+ path - Path to model file
14
+ __________________________________________________________________________
15
+
16
+
17
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_shp_get_model.m )
18
+
19
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
20
+ """
21
+ return Runtime.call("spm_shp_get_model", *args, **kwargs)
@@ -0,0 +1,32 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_shp_get_transforms(*args, **kwargs):
5
+ """
6
+ Transform MRI to model space and compute its latent code
7
+
8
+ FORMAT spm_shp_get_transforms(path_mri,[folder_out],[folder_shp])
9
+
10
+ path_mri - Path to input MRI
11
+ folder_out - Path to output folder (default: {input_folder}/PCA)
12
+ folder_shp - Path to template folder (default: {spm('Dir')}/tpm/shp)
13
+ z - Latent vectors describing the space in which the MRI lives
14
+
15
+ The following files are written in folder_out:
16
+ * pca_{mri_name}.mat - Shape representation of the MRI
17
+ 'z' - Latent vector
18
+ 'r2n' - Import to native affine transform
19
+ 'n2r' - Native to import affine transform
20
+ * {mri_name}.nii - Copy of input MRI
21
+ * v_{mri_name}.nii - Initial velocity (in import space)
22
+ * iv_{mri_name}.nii - Initial velocity (in group space)
23
+ * y_{mri_name}.nii - Import to group nonlinear transform
24
+ * iy_{mri_name}.nii - Group to import nonlinear transform
25
+ __________________________________________________________________________
26
+
27
+
28
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_shp_get_transforms.m )
29
+
30
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
31
+ """
32
+ return Runtime.call("spm_shp_get_transforms", *args, **kwargs)
spm/spm_shp_install.py ADDED
@@ -0,0 +1,16 @@
1
+ from spm.__wrapper__ import Runtime
2
+
3
+
4
+ def spm_shp_install(*args, **kwargs):
5
+ """
6
+ Download files required for Shape PCA model
7
+
8
+ FORMAT datadir = spm_shp_install(datadir,[force=true])
9
+ __________________________________________________________________________
10
+
11
+
12
+ [Matlab code]( https://github.com/spm/spm/blob/main/spm_shp_install.m )
13
+
14
+ Copyright (C) 2024-2024 Functional Imaging Laboratory, Department of Imaging Neuroscience, UCL
15
+ """
16
+ return Runtime.call("spm_shp_install", *args, **kwargs)