-
Notifications
You must be signed in to change notification settings - Fork 6
statistical pipeline
To do the statistical analysis, the wild type specimens and mutant lines need to have previously been run through the registration pipeline
One this has been done, you should have three folders with the following names:
- baseline - containing the baseline registration results
- mutant - containing the mutant line registration results
- target - containing the population average and associated files (label maps, label name files etc)
In each specimen folder of the mutant and baseline folders there will be a CSV that contains the whole embryo volume information named staging_info_volume.csv.
- The staging info from each specimen is collated from the staging CSV files.
The stats config file is in yaml format (http://yaml.org/)
stats_types:
- jacobians
- intensity
- organ_volume
reg_folder: similarity
jac_folder: 1928
mask: mask_tight.nrrd
label_info: label_info.csv
label_map: labels.nrrd
blur_fwhm: 100
voxel_size: 14.0
stats_types: list the analysis types to do (currently three available)
reg_folder: the name of the registration sub-folders to use This will be the name of the final registration stage (todo: get this automatically)
jac_folder: the name of the jacobian determinant folder name to use todo (make this optional as generally we produce jacobians from only one registration stage
mask: The name of the mask to use for statistical analysis This could be a different mask than that used for registration. We have noticed that too tight a mask for registration can call problems. Whereas we might want a tighter mask for removing data points outside of the embryo.
label_info: name of the label info file. See Input data
label_map: name of the label map. See [Input data(/input_data#label-map)
blur_fwhm: the size of the guassian blur kernal (full width half maximum in micrometers)
voxel_size: the voxel size of the input images in micrometers
# Activate the virtual environment
$ cd lama_phenotype_detection
$ pipenv shell
# Run the script
$ lama_stats.py -c <path to stats config> -w <Path to wild type directory> -m <Path to mutant directory> -t <path to target directory> -o <path to output directory>
In the output folder (specified with the -o argument) There will be a folder for each line processed. In that folder will be subfolders containing the output of each analysis type.
In the following example mutant1 has results fro the jacobian analysis. The nrrd file named line_jacobians.nrrd are the line-level results, and the files with the specimen names in them are the specimen-level results.
These images can be analysed using the image viewer VPV that we have developed.
There are instructions on how to loo at statistical heatmaps in vpv here.