Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
title: "On the distribution of p-values" | |
output: html_notebook | |
--- | |
```{r} | |
sample.sizes <- seq(5, 100, 10) | |
num.trials <- 1000 | |
num.experiments <- 1 | |
null.mu <- 0.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let swap arr i j = | |
let tmp = arr.(j) in | |
arr.(j) <- arr.(i); | |
arr.(i) <- tmp | |
let partition arr l h = | |
let pivot = arr.(h) in | |
let i = ref @@ (l - 1) in | |
for j = l to h - 1 do | |
if arr.(j) <= pivot then begin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let swap arr i j = | |
let tmp = arr.(j) in | |
arr.(j) <- arr.(i); | |
arr.(i) <- tmp | |
let partition arr l h = | |
let pivot = arr.(h) in | |
let i = ref @@ (l - 1) in | |
for j = l to h - 1 do | |
if arr.(j) <= pivot then begin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# pymedio is used here because it opens a wide variety of | |
# medical image formats but you can use 'nibabel', 'pydicom', | |
# or 'SimpleITK' and extract the pixel data as an array and | |
# use the same functions to test equality | |
from pymedio.image import Image | |
# 'query_image' and 'target_image' can be most common medical | |
# image formats, e.g., NIfTI, directory of DICOM frames, etc. | |
query = Image.from_path("path/to/query_image") | |
target = Image.from_path("path/to/target_image") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Normalize the intensity of a CT image | |
Author: Jacob Reinhold | |
""" | |
import sys | |
from argparse import ArgumentParser | |
from pathlib import Path | |
from typing import Tuple, Union |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Normalize the intensity of an image by | |
finding a tissue mean in the foreground and | |
voxel-wise dividing the image by that value | |
Author: Jacob Reinhold | |
""" | |
import sys | |
from argparse import ArgumentParser |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Normalize the intensity of a set of images by | |
finding a tissue mean in the foreground and | |
voxel-wise dividing the image by that value | |
Author: Jacob Reinhold | |
""" | |
import os | |
import re |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Normalize the intensity of a set of images by | |
finding a specified peak of each image foreground intensity | |
and voxel-wise dividing the image by that value | |
Author: Jacob Reinhold | |
""" | |
import os | |
import re |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
"""Normalize the intensity of a set of images by | |
finding the specified percentile of each image | |
foreground and voxel-wise dividing the image by that value | |
Author: Jacob Reinhold | |
""" | |
import os | |
import re |
NewerOlder