'[<-.disto' {disto}R Documentation

In-place replacement of values

Description

For dist backend see: dist_replace.

Usage

## S3 replacement method for class 'disto'
x[i, j, k] <- value

Arguments

x

object of class 'disto'

i

(integer vector) row index

j

(integer vector) column index

k

(integer vector) direct index

value

(integer/numeric vector) Values to replace

Value

Invisible disto object. Note that this function is called for its side effect.

Examples

temp       <- stats::dist(iris[,1:4])
dio        <- disto(objectname = "temp")
names(dio) <- paste0("a", 1:150)
dio

dio[1, 2] <- 10
dio[1,2]

dio[1:10, 2:11] <- 100
dio[1:10, 2:11, product = "inner"]

dio[paste0("a", 1:5), paste0("a", 6:10)] <- 101
dio[paste0("a", 1:5), paste0("a", 6:10), product = "inner"]

[Package disto version 0.2.0 Index]