fill |

Fill a matrix object with specified values.

Syntax

matrix_name.fill(options) n1[, n2, n3 …]

Follow the keyword with a list of values to place in the matrix object. Each value should be separated by a comma.

Running out of values before the object is completely filled is not an error; the remaining cells or observations will be unaffected, unless the “l” option is specified. If, however, you list more values than the object can hold, EViews will not modify any observations and will return an error message.

Options

l | Loop repeatedly over the list of values as many times as it takes to fill the object. |

o=integer (default=1) | Fill the object starting from the specified element. Default is the first element. |

b=arg (default=“c”) | Matrix fill order: “c” (fill the matrix by column), “r” (fill the matrix by row). |

Examples

The commands,

matrix(2,2) m1

matrix(2,2) m2

m1.fill 1, 0, 1, 2

m2.fill(b=r) 1, 0, 1, 2

create the matrices:

(1.2) |

Cross-references

See
“Matrix Language” for a detailed discussion of vector and matrix manipulation in EViews.