Covariance Matrix

Hi all.

I need help on the following…

I’m fitting with a combination of functions, e.g. linear+gaussian. But I want to get the IntegralError of one of the functions (either the linear or the gaussian).

So I think I have to get the covariance matrix

TVirtualFitter *fitter = TVirtualFitter::GetFitter();
double * covMatrix = fitter->GetCovarianceMatrix();

and then distinguish in there the part that corresponds to the function I want?

Many thanks in advance…

hi,

first get the full covariance matrix
then get only the indices of the matrix matching to your pol or gaus parameters.

for pol(2)+gaus, matrix will have (3+3)*(3+3) size : (pol(2)=[0]+[1]*x+[2]xx)
i=0,2 and j=0,2 will give pol(2) cov. matrix elements
i=3,5 and j=3,5 will give gaus’s.

i=0,2/j=3,5 or i=3,5/j=0,2 will give cov. elements beween pol and gaus parameters

also consider getting correlation matrix instead f covariance matrix.

Thanks a lot!