Home > brede > brede_mat_sem_grow.m

brede_mat_sem_grow

PURPOSE ^

brede_mat_sem_grow - Grow structural equation model

SYNOPSIS ^

function [K, Psi] = brede_mat_sem_grow(M, varargin)

DESCRIPTION ^

 brede_mat_sem_grow   - Grow structural equation model

       [K, Psi] = brede_mat_sem_grow(M, 'PropertyName', 'PropertyValue') 
   
       Input:    M      'Mat' structure with data matrix
   
       Property: Kinit  'Mat' structure with initial structure matrix 
                 Knew   'Mat' structure

       Output:   K      'Mat' structure with new structure matrix 
                 Psi    'Mat' structure with new noise matrix

       Function for "growing" a structural equations model with the
       simple from:  

                 X = X * K + U
    
       Each time the function is call a new non-zero element is added
       to the structure matrix. If the function is called without the
       'Kinit' property, then a all-zero structure matrix is used as
       the start. 

       Presently, the element that is added is the element that
       increases the likelihood the most as found by brute force
       search over all possible additions. The property 'Knew' kan be
       defined setting element to NaN for those elements in the
       structure matrix that should not be grown.

       Example:
         % Construct artificial data set
         Ktrue = [ 0 1 -0.3 ; 0 0 0 ; 0 0 0 ]
         X = randn(1000,3)*pinv(eye(3)-Ktrue); 

         % Estimate first element in the structure matrix
         K1 = brede_mat_sem_grow(X)
         K1.matrix

         % Grow a second element in the structure matrix
         K2 = brede_mat_sem_grow(X, 'Kinit', K1)
         K2.matrix
 
       See also BREDE, BREDE_MAT, BREDE_MAT_SEM, BREDE_MAT_SEM_BIC,
                BREDE_MAT_SEM_LOGLIKELIHOOD.

 $Id: brede_mat_sem_grow.m,v 1.4 2008/07/01 14:15:46 fn Exp $

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Fri 27-Nov-2009 18:11:22 by m2html © 2005