| Search Locate Previous Next | Contents |
The examples in this and subsequent topics use a number of APL arrays:
sales | a 4 by 21 by 6 numeric array containing quarterly sales revenue in thousands of dollars by product by district for the ACME Intergalactic Shoe Corporation Inc. The bottom row and the rightmost column of each plane are totals. Each district is associated with one of two geographic regions. |
salesQ1 | the sales revenue for the first quarter, the first plane of sales. |
salesTot | the total sales revenue for all quarters. |
products | is a vector of text vectors, the names of the products. |
districts | is a vector of text vectors, the names of the sales districts. |
regions | is a vector of text vectors, one per district, the names of the regions. |
To create them, type:
sales4.1×?4 20 5½1000 salessales,+/sales salessales,[2]+/[2]sales salesTot+sales salesQ1sales[1;;] products(('Product '),¨¨¼20),'Total' districts(('District '),¨¨¼5),'Total' regions2 3 1/'North' 'South' ''
Correcting errors
If execution stops within a NewLeaf function, type:
leaf.Close
Then, try to locate the reason for the error by comparing your code with that in the tutorial topic. If you are experimenting with code not found in a tutorial, ensure that the shape and depth of the variable arguments correspond to those in the examples.