其他分享
首页 > 其他分享> > Li‘s 核磁共振影像数据处理-22-FSL常用工具命令介绍 fslutils

Li‘s 核磁共振影像数据处理-22-FSL常用工具命令介绍 fslutils

作者:互联网

讲解视频内容请移步Bilibili:
https://space.bilibili.com/542601735
入群讨论请加v hochzeitstorte
请注明“核磁共振学习”
公众号:美好事物中转站

今日代码

查看影像基本信息
fslinfo MNI152_T1_2mm_brain.nii.gz

在这里插入图片描述
查看影像更加详细的信息
fslhd MNI152_T1_2mm_brain.nii.gz
选填参数 -x,以XML格式输出。
“Don’t worry if you don’t know what every field means.”

在这里插入图片描述

各种统计量

fslstats MNI152_T1_2mm_brain.nii.gz -m -M
使用方法和可选参数:
Usage: fslstats [preoptions] [options]

preoption -t will give a separate output line for each 3D volume of a 4D timeseries
preoption -K < indexMask > will generate seperate n submasks from indexMask, for indexvalues 1…n where n is the maximum index value in indexMask, and generate statistics for each submask
Note - options are applied in order, e.g. -M -l 10 -M will report the non-zero mean, apply a threshold and then report the new nonzero mean

-l : set lower threshold
-u : set upper threshold
-r: output
-R: output
-e: output mean entropy ; mean(-i*ln(i))
-E: output mean entropy (of nonzero voxels)
-v: output
-V: output (for nonzero voxels)
-m: output mean
-M: output mean (for nonzero voxels)
-s: output standard deviation
-S: output standard deviation (for nonzero voxels)
-w: output smallest ROI containing nonzero voxels
-x: output co-ordinates of maximum voxel
-X: output co-ordinates of minimum voxel
-c: output centre-of-gravity (cog) in mm coordinates
-C: output centre-of-gravity (cog) in voxel coordinates
-p : output nth percentile (n between 0 and 100)
-P : output nth percentile (for nonzero voxels)
-a: use absolute values of all image intensities
-n: treat NaN or Inf as zero for subsequent stats
-k : use the specified image (filename) for masking - overrides lower and upper thresholds
-d : take the difference between the base image and the image specified here
-h : output a histogram (for the thresholded/masked voxels only) with nbins
-H : output a histogram (for the thresholded/masked voxels only) with nbins and histogram limits of min and max

Note - thresholds are not inclusive ie lthresh<allowed<uthresh

影像文件分割

fslsplit dwidata.nii.gz dwidata/vol

影像文件合并

fslmerge -t dwidata_merge vol*

影像剪切、尺寸调整

fslroi MNI152_T1_2mm_brain.nii.gz MNI152_T1_2mm_brain_resize.nii.gz -5 101 -5 119 -5 101

标签:nonzero,nii,22,fslutils,gz,voxels,output,常用工具,mean
来源: https://blog.csdn.net/weixin_38594676/article/details/120586909