Description Usage Arguments Details Value Author(s) See Also Examples
This function creates two dimensional phantom data. There are different options, e.g. to generate a big ellipse that represents the head, and several smaller ellipses, that represent pathological areas to be located in the space of the bigger ellipse.
1 | phantom(n = 257, design = "A", addIm = "none", DebugLevel = "Normal")
|
n |
(integer) Is the number of columns and rows in the generated phantom. It is assumed that the number of columns is equal to the number of rows. Defaults to |
design |
(character) |
addIm |
(character) Adds an additional image to the phantom. There are six default-designs for |
DebugLevel |
(character) This parameter controls the level of output. Defaults to |
design
:
To define an own design of the phantom (e.g. design=P
) you have to note the following conditions:
P
is a (n,5) or (n,6) matrix, whereas n > 0.
All elements x of P
have to be between -1 and 1.
Each row from P
define a ellipse on [-1,1]^2, where
[,1] | A | Is the additive intensity of the corresponding ellipse. |
[,2] | x_0 | Is the x-coordinate of the center of the ellipse. |
[,3] | y_0 | Is the y-coordinate of the center of the ellipse. |
[,4] | a | Is the half length of the horizontal axis. |
[,5] | b | Is the half length of the vertical axis. |
[,6] | α | Is the angle in degree between the x-axis of the ellipse |
and the x-axis of the grid. This parameter is optional, | ||
but the number of columns have to be the same in all rows. | ||
Returns a phantom image.
Joern Schulz jschulz78@web.de.
1 2 3 4 5 6 7 8 9 10 11 | P1 <- phantom()
P2 <- phantom(addIm="blurred1")
PhPa1 <- c(0.5, 0, 0, 0.4, 0.6)
PhPa2 <- matrix( c(0.6, -0.35, 0, 0.4, 0.6,
0.3, 0.5, 0, 0.2, 0.35), nrow=2, byrow=TRUE )
P3 <- phantom(design=PhPa1)
P4 <- phantom(design=PhPa2)
viewData(list(P1, P2, P3, P4), list("Default Phantom",
"addIm='blurred1'", "First new design",
"Second new design"))
rm(P1,P2,P3,P4,PhPa1,PhPa2)
|
Loading required package: adimpro
Loading required package: awsMethods
Use the function setCores() to change the number of CPU cores.
sh: 1: cannot create /dev/null: Permission denied
sh: 1: cannot create /dev/null: Permission denied
sh: 1: cannot create /dev/null: Permission denied
Reading RAW images requires to install dcraw, see
http://cybercom.net/~dcoffin/dcraw/ for LINUX and http://www.insflug.org/raw/
for MAC OS and Windows
Attaching package: 'PET'
The following object is masked from 'package:base':
norm
Warning message:
In fun(libname, pkgname) : could not determine path to Imagemagick
please set the correct path manually using
'Sys.setenv(ImageMagick='path2imagemagick')'
Creation of the source-data --> complete.
Creation of the source-data --> Start of function halfCircle.
The calculation need a few of minutes --> complete.
complete.
Creation of the source-data --> complete.
Creation of the source-data --> complete.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.