clone

From DavinciWiki
Jump to: navigation, search


64-bit SafeYes

Description

Duplicate an object many times.

Arguments and Return Values

Arguments: A numeric value or array and X, Y, and Z dimension values.

Return Value: An X by Y by Z numeric array full of copied values.

Usage

Syntax: clone(object = VAL [,x = INT] [,y = INT] [,z = INT])

The clone() function dupicates the specified object X*Y*Z times, and concatenates these objects together the specified number of time along each axis. Any of the X, Y or Z values that are not specified defualt to a value of 1.

Examples

 dv> a = clone(1.05,3,3,1)
 3x3x1 array of float, bsq format [36 bytes]
 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000

 dv> b = clone(a,2,1,2)
 6x3x2 array of float, bsq format [144 bytes]
 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000

 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000
 1.05000 1.05000 1.05000 1.05000 1.05000 1.05000

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: 07-06-2009

Personal tools