Functions Utility

CreateMatrix

The CreateMatrix() function generates a random block of test data.


Syntax:

Qx.CreateMatrix(Rows, Columns, Data Generation Pattern)
  • In Excel with Quintessence addin versions prior to 25.1, use: CreateMatrix()
  • In the Quintessence Editor (Studio) using Quintessence language, use: CreateMatrix()
  • In the Quintessence Editor (Studio) using Python language, use: Qx.CreateMatrix()
See parameter descriptions

RowsThe number of rows to generate.
ColumnsThe number of columns to generate
Data Generation Pattern
(optional)
Predefined set of rules for creating synthetic or test data in a consistent and repeatable way.

Remarks:

  • Unless changed by an administrator, the default parameters are:
    • Data Generation Pattern: random

Examples:

The examples provided below are based on fictitious data for illustrative purposes only.

> Example 1: Create a random 2×3 array


This can be achieved by calling the function as follows:

=Qx.CreateMatrix(2, 3)

Result: (values will differ because they are randomly generated)

256.1369966.224309.7549
14.313817.174246917.6893
> Example 2: Create a 2×3 array where all values are the same


This can be achieved by calling the function as follows:

=Qx.CreateMatrix(2, 3, "Hello World!")

Result:

Hello World!Hello World!Hello World!
Hello World!Hello World!Hello World!
> Example 3: Create a 3×3 identity matrix


This can be achieved by calling the function as follows:

=Qx.CreateMatrix(3, 3, "identity")

Result:

100
010
001