resize

From DavinciWiki
Revision as of 11:18, 6 July 2009 by Cedwards (Talk | contribs)

Jump to: navigation, search


64-bit SafeYes

Description

Resize dimensions of array retaining number of elements

Arguments and Return Values

Arguments: A numeric array and x, y and z values

Return Value: A numeric array of specified dimensions

Usage

Syntax: resize(obj = VAL, x = INT, y = INT, z = INT [, org = ORG])

The product of the new dimensions must equal to the product of the original dimensions. The resize() function cannot create or destroy elements it can only rearrange them.

Examples

dv> a
45x10x2 array of float, bsq format [3,600 bytes]

dv> b = resize(a,45,10,2)
45x10x2 array of float, bsq format [3,600 bytes]

dv> b = resize(a,45,20,1)
45x20x1 array of float, bsq format [3,600 bytes]

dv> b = resize(a,45,10,3)
Illegal dimensions: 45x10x3 != 900

DavinciWiki Mini-Nav Bar

Contents


Contact Developers

  • davinci-dev [AT] mars.asu.edu

All other topics

  • See navigation on the left

Related Functions

Recent Core Changes

Modified On: 11-05-2012

Personal tools