tscale {tropAlgebra}R Documentation

Tropical Scaling of Matrix Or vector

Description

This function returns the scaled matrix or vector Y by a value x .This function works only if Y is matrix or vector and x is a numeric value.

Usage

tscale(x,y)

Arguments

x

A numeric value.

y

A numeric matrix or a numeric vector.

Details

If the given argument x is not a numeric value or argument Y is not a numeric matrix or a numeric vector then this function generates an error.

Value

Returns the scaled Y.

Examples


x<-5
y<-matrix(c(2,3,5,7),ncol=2,nrow=2)
tscale(x,y)
y<-c(1,2,3)
tscale(x,y)

[Package tropAlgebra version 0.1.1 Index]