MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Question from newbabie

  • To: mathgroup at
  • Subject: [mg33873] Re: [mg33831] Question from newbabie
  • From: BobHanlon at
  • Date: Sun, 21 Apr 2002 06:12:19 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

In a message dated 4/19/02 3:44:44 AM, antispam at writes:

>Hi... I am new to Mathematica, so please forgive me if this question
>is naive.
>Can you tell me how can I do the following?
>Differentiate the log likelihood for multi-variate Gaussian with
>respect to the covariance matrix, and then solve the log-likelihood
>I know how to do that manually, but I would like to learn how to
>do that in Mathematica. Thank you.


dist = MultinormalDistribution[{m1,m2}, {{1,r},{r,1}}];

      dist /. {m1->3, m2->5, r->1/2},{100}];

eqn= (D[Tr[PowerExpand[Log[
                          PDF[dist, {#[[1]],#[[2]]}]]]& /@
                    data], #]& /@ {m1,m2,r})==0;

FindRoot[eqn, {m1,1},{m2,1},{r,.1}]

{m1 -> 2.91689, m2 -> 5.02367, r -> 0.571814}

Bob Hanlon
Chantilly, VA  USA

  • Prev by Date: Re: How Do You Reduce Multiple Elements in a List?
  • Next by Date: RE: How Do You Reduce Multiple Elements in a List?
  • Previous by thread: Question from newbabie
  • Next by thread: Closed Polygons from List