dim.lpExtPtr function

Dimension of an Object

Dimension of an Object

Retrieve the dimension (number of rows and columns) from an lpSolve linear program model object.

## S3 method for class 'lpExtPtr' dim(x) ## S3 replacement method for class 'lpExtPtr' dim(x) <- value

Arguments

  • x: an lpSolve linear program model object.
  • value: assignment is not supported.

Details

Setting the number of rows/columns is not supported. See resize.lp.

Returns

an integer vector of length two containing the number of rows and the number of columns in the lpSolve linear program model object.

References

https://lpsolve.sourceforge.net/5.5/index.htm

Author(s)

Kjell Konis kjell.konis@me.com

See Also

resize.lp

Examples

lps.model <- make.lp(4, 0) x <- c(6,2,4,9) add.column(lps.model, x) y <- c(3,1,5) ind <- c(1,2,4) add.column(lps.model, y, ind) dim(lps.model)
  • Maintainer: Florian Schwendinger
  • License: LGPL-2
  • Last published: 2024-07-19

Useful links