SED navigation bar go to SED home page go to Dataplot home page go to NIST home page SED Home Page SED Staff SED Projects SED Products and Publications Search SED Pages
Dataplot Vol 2 Vol 1

MATRIX COMBINE ROWS

Name:
    MATRIX COMBINE ROWS (LET)
Type:
    Let Subcommand
Purpose:
    Combine two matrices by rows.
Description:
    It is sometimes convenient to extend the rows of one matrix with the rows of another matrix. For example, given the matrices

     
            M1 = | 1   2 |
                 | 3   4 |
        
    and
     
            M2 = | 5   6 |
                 | 7   8 |
        

    this command will generate the matrix

     
            M3 = | 1   2 |
                 | 3   4 |
                 | 5   6 |
                 | 7   8 |
        

    This command requires that the two input matrices have the same number of columns.

Syntax:
    LET <m3> = MATRIX COMBINE ROWS <m1> <m2>
    where <m1> is the first input matrix;
                <m2> is the second input matrix;
    and      <m3> is the resulting matrix.

    Note that <m3> can be the same name as either <m1> or <m2>.

Examples:
    LET M3 = MATRIX COMBINE ROWS M1 M2
    LET MOUT = MATRIX COMBINE ROWS M1 M2
Note:
    Matrices can be created with the READ MATRIX, CREATE MATRIX or MATRIX DEFINITION commands.
Default:
    None
Synonyms:
    MATRIX COMBINE ROW
Related Commands: Applications:
    Multivariate Analysis
Implementation Date:
    2011/1
Program:
     
    dimension 100 columns
    .
    read matrix m1
    1 2
    3 4
    end of data
    .
    read matrix m2
    5 6
    7 8
    end of data
    .
    let m3 = matrix combine row m1 m2
    .
    set write decimals 0
    print m3
        
    The following output is generated.
            MATRIX M3      --            4 ROWS
                           --            2 COLUMNS
    
     VARIABLES--M31            M32     
    
              1              2
              3              4
              5              6
              7              8
        

Date created: 01/26/2011
Last updated: 01/26/2011
Please email comments on this WWW page to alan.heckert@nist.gov.