Documentation 
Loglikelihood function for leastsquares regression with missing data
Objective = ecmlsrobj(Data, Design, Parameters, Covariance)
Data  NUMSAMPLESbyNUMSERIES matrix with NUMSAMPLES samples of a NUMSERIESdimensional random vector. Missing values are represented as NaNs. Only samples that are entirely NaNs are ignored. (To ignore samples with at least one NaN, use mvnrmle.) 
Design  A matrix or a cell array that handles two model structures:

Parameters  NUMPARAMSby1 column vector of estimates for the parameters of the regression model. 
Covariance  (Optional) NUMSERIESbyNUMSERIES matrix that contains a usersupplied estimate for the covariance matrix of the residuals of the regression. Default is an identity matrix. 
Objective = ecmlsrobj(Data, Design, Parameters, Covariance) computes a leastsquares objective function based on current parameter estimates with missing data. Objective is a scalar that contains the leastsquares objective function.
ecmlsrobj requires that Covariance be positivedefinite.
Note that
ecmlsrobj(Data, Design, Parameters) = ecmmvnrobj(Data, ... Design, Parameters, IdentityMatrix)
where IdentityMatrix is a NUMSERIESbyNUMSERIES identity matrix.
You can configure Design as a matrix if NUMSERIES = 1 or as a cell array if NUMSERIES ≥ 1.
If Design is a cell array and NUMSERIES = 1, each cell contains a NUMPARAMS row vector.
If Design is a cell array and NUMSERIES > 1, each cell contains a NUMSERIESbyNUMPARAMS matrix.