ships: R6 class for ships data

Description Methods Examples

Description

R6 class for ships data

R6 class for ships data

Methods

Public methods


Method new()

data import and calculations

Usage
ships$new(path, mem = TRUE)
Arguments
path

character path to *.rds file

mem

logical save memory? Otherwise, the complete data is stored

Returns

ships R6 instance

Examples
\dontrun{test <- ships$new(inst/extdata/ships.rds)}

Method display_ship()

Display Leaflet map

Usage
ships$display_ship(sel_type, sel_name)
Arguments
sel_type

selected ship type

sel_name

selected ship name

Examples
\dontrun{test$display_ship("Cargo", "KAROLI")}

Method clone()

The objects of this class are cloneable with this method.

Usage
ships$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## ------------------------------------------------
## Method `ships$new`
## ------------------------------------------------

## Not run: test <- ships$new(inst/extdata/ships.rds)

## ------------------------------------------------
## Method `ships$display_ship`
## ------------------------------------------------

## Not run: test$display_ship("Cargo", "KAROLI")

phit0/ships documentation built on Dec. 22, 2021, 8:40 a.m.