order.ijdata: Order IJDATA spot sequences and growth lines

Description Usage Arguments Details Author(s) See Also Examples

View source: R/order.ijdata.R

Description

Reorders spot sequences and growth lines within object of class IJDATA.

Usage

1
order.ijdata(IJDATA, spots = "", gbs = "", print.order = FALSE)

Arguments

IJDATA

an IJDATA object.

spots

a character or numeric vector specifying the desired order of sample spot sequences.

gbs

a character or numeric vector specifying the desired order of growth lines.

print.order

logical. Should the current order of spot sequences and growth lines be printed instead of changing the order?

Details

Reorders IJDATA spot.x and spot.y and/or gbs.x and gbs.y coordinate data.frames. Useful when order of ROIs does not correspond with the desired order of convert.ijdata or spot.dist output. Can also be used to print the order of spot sequences and growth lines within IJDATA object (see 'print.order'). In addition the function can also be used to drop spot sequences or growth lines from the data set by leaving out ROI names. In this case a warning is produced to confirm that the user has not forgotten something.

Author(s)

Mikko Vihtakari

See Also

read.ijdata for reading zip files containing ImageJ ROIs.

convert.ijdata for converting the coordinate information to spatstat point patterns.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
data(shellspots)
order.ijdata(shellspots, print.order = TRUE) # Prints the current order. Does not change anything
dat <- order.ijdata(shellspots, gbs = c(1,3,6:14,4,5,2)) # Changes order of growth bands
order.ijdata(dat, print.order = TRUE)

## Subset the first sample spot sequence
dat2 <- order.ijdata(shellspots, gbs = 1:13)
## Warning message:
## In order.ijdata(shellspots, gbs = 1:13) :
## Length of gbs does not correspond the number of columns. Data removed.
order.ijdata(dat2, print.order = TRUE)

sclero documentation built on May 2, 2019, 2:26 p.m.