myGrid: Methods for 'myGrid' objects.

Description Usage Arguments Details Author(s) See Also Examples

Description

Methods for the result of initGrid (myGrid object)

Usage

1
2
3
4
5
6
7
8
## S3 method for class 'myGrid'
print(x, ...)

## S3 method for class 'myGrid'
summary(object, ...)

## S3 method for class 'myGrid'
plot(x, show.names = TRUE, names = 1:prod(x$dim), ...)

Arguments

x

myGrid object

...

Further arguments to the plot function.

object

myGrid object

show.names

Whether the cluster names must be printed in center of the grid or not. Default to TRUE (names not displayed).

names

If show.names = TRUE, values of the names to display. Default to the cluster number.

Details

The myGrid class has the following entries:

During plotting, the color filling process uses the coordinates of the object x included in x$coord.

Author(s)

Élise Maigné <elise.maigne@inrae.fr>
Madalina Olteanu, olteanu@ceremade.dauphine.fr
Nathalie Vialaneix, nathalie.vialaneix@inrae.fr

See Also

initGrid to define a myGrid class object.

Examples

1
2
3
4
5
6
7
8
9
# creating grid
a.grid <- initGrid(dimension=c(5,5), topo="square", dist.type="maximum")

# plotting grid
# without any color specification
plot(a.grid)
# generating colors from rainbow() function
my.colors <- grDevices::rainbow(5*5)
plot(a.grid) + ggplot2::scale_fill_manual(values = my.colors)

SOMbrero documentation built on Jan. 4, 2022, 1:07 a.m.