DesignSUR = convert2sur(Design,Group)
converts a multivariate normal regression model into a seemingly unrelated
regression model with a specified grouping of the data series.

This example shows a CAPM demonstration using 6 stocks and 60 months of simulated asset returns, where the model for each stock is AssetReturn = Alpha * 1 + CashReturn + Beta * (MarketReturn - CashReturn) + Noise and the parameters to estimate are Alpha and Beta.

Using simulated data, where the Alpha estimate(s) are displayed in the first row(s) and the Beta estimate(s) are display in the second row(s).

Data series, specified as a matrix or a cell array that depends on the
number of data series NUMSERIES.

If NUMSERIES = 1,
convert2sur returns the
Design matrix.

If NUMSERIES > 1, Design
is a cell array with NUMSAMPLES cells, where each
cell contains a
NUMSERIES-by-NUMPARAMS
matrix of known values.

Data Types: double | cell

Group — Grouping for data series vector | cell array

Grouping for data series, specified using separate parameters for each
group. Specify groups either by series or by groups:

To identify groups by series, construct an index vector that has
NUMSERIES elements. Element i = 1,
..., NUMSERIES in the vector, and has the index
j = 1, ..., NUMGROUPS of the group in which
series i is a member.

To identify groups by groups, construct a cell array with
NUMGROUPS elements. Each cell contains a
vector with the indexes of the series that populate a given
group.

In either case, the number of series is
NUMSERIES and the number of groups is
NUMGROUPS, with 1 ≤
NUMGROUPS ≤ NUMSERIES.

DesignSUR — Seemingly unrelated regression model with a specified grouping of the data series matrix | cell array

Seemingly unrelated regression model with a specified grouping of the data
series, returned as either a matrix or a cell array that depends on the
value of NUMSERIES.

If NUMSERIES = 1, DesignSUR =
Design, which is a
NUMSAMPLES-by-NUMPARAMS
matrix.

If NUMSERIES > 1 and
NUMGROUPS groups are to be formed,
Design is a cell array with
NUMSAMPLES cells, where each cell
contains a NUMSERIES-by-(NUMGROUPS *
NUMPARAMS) matrix of known values.

The original collection of parameters that are common to all series are
replicated to form collections of parameters for each group.

You can also select a web site from the following list:

How to Get Best Site Performance

Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.