MathGroup Archive 2011

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

Search the Archive

Re: TransformedDistribution -- odd problem

  • To: mathgroup at smc.vnet.net
  • Subject: [mg121089] Re: TransformedDistribution -- odd problem
  • From: paulvonhippel at yahoo <paulvonhippel at yahoo.com>
  • Date: Fri, 26 Aug 2011 05:26:36 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <j0gh7s$bd7$1@smc.vnet.net> <201107251129.HAA25540@smc.vnet.net>

Here is a variant of the same difficulty. In the input I specify that
v2>2, yet in the output I get two solutions, one of which only applies
if v2<=2.
Many thanks if you can tell me what I'm doing wrong. I believe my
mistake here may be causing more serious problems in more complicated
input.

In[3]:= Assuming[v2 > 2,
  Mean[TransformedDistribution[
    w, {w \[Distributed] FRatioDistribution[v1, v2]}]]] // InputForm

Out[3]//InputForm=
Piecewise[{{v2/(-2 + v2), v2 > 2}}, Indeterminate]

On Jul 26, 6:09 am, Paul von Hippel <paulvonhip... at yahoo.com> wrote:
> Thanks -- that fixes it!
>
> Bonus question: if we don't specify v2>2, why doesn't Mathematica return a two part solution:
>  k v2 / (v2-2) v2>2
>
>  Indeterminate True
>
> That's what it does if we request the mean of F -- why doesn't it do the same if we request the mean of k*F.
>
> ________________________________
> From: Barrie Stokes <Barrie.Sto... at newcastle.edu.au>
> Sent: Monday, July 25, 2011 8:09 PM
> Subject: Re: TransformedDistribution -- odd problem
>
> Hi Paul
>
> There are conditions on the v1 and v2, the degrees of freedom of the F distribution:
>
> Assuming[v2 > 2,
> Mean[TransformedDistribution[F ,
>   F \[Distributed] FRatioDistribution[v1, v2]]]]
>
> {Assuming[v2 > 2,
>  Mean[TransformedDistribution[k*F ,
>   F \[Distributed] FRatioDistribution[v1, v2]]]], k*v2/(-2 + v2)}
>
> {Assuming[v2 > 2,
>   Mean[TransformedDistribution[k + F ,
>    F \[Distributed] FRatioDistribution[v1, v2]]]],
>  k + v2/(-2 + v2)} // FullSimplify
>
> which shows precisely what you expect for k*F and k+F.
>
> Cheers
>
> Barrie
>
> >>> On 25/07/2011 at 9:29 pm, in message <201107251129.HAA25... at smc.vnet.net>,
>
> paulvonhippel at yahoo <paulvonhip... at yahoo.com> wrote:
>
>
>
>
>
>
>
> > A little more experimenting shows that the TransformedDistribution
> > function will also not provide the mean of k+F where k is a constant
> > and F has an F distribution -- i.e.,
> >  Mean[TransformedDistribution[k*F ,  F \[Distributed]
> > FRatioDistribution[v, v]]]
>
> > If I changce the distribution of F to NormalDistribution or
> > ChiSquareDistribution, I can get a mean for k*F or k+F. So the problem
> > only occurs when I define a simple function of an F variable using the
> > TransformedDistribution function.
> > This all strikes me as very strange, and I'd be curious to know if
> > others can reproduce my results. If you can't reproduce my results,
> > I'd be interested in theories about why my results differ from yours.
> > E.g., is there a setting I should change in the software?
>
> > I am using version 8.0.0.0 and looking to upgrade to 8.0.1, if that
> > makes a difference.
>
> > Many thanks for any pointers.
>
> > On Jul 24, 2:22 am, paulvonhippel at yahoo <paulvonhip... at yahoo.com>
> > wrote:
> >> I'm having a very strange problem with TransformedDistribution, where
> >> I can calculate the mean of an F distribution but I cannot calculate
> >> the mean of a constant multiplied by an F distribution. That is, if I
> >> type
>
> >>  Mean[TransformedDistribution[F, F \[Distributed]
> >> FRatioDistribution[v, v]]]
>
> >> Mathematica gives me an answer. But if I type
>
> >>  Mean[TransformedDistribution[k*F ,  F \[Distributed]
> >> FRatioDistribution[v, v]]]
>
> >> Mathematica just echoes the input. I swear I got an answer for the
> >> second expression earlier today. What am I doing wrong?





  • Prev by Date: Re: FindRoot repeatedly evaluating function
  • Next by Date: Re: FindRoot repeatedly evaluating function
  • Previous by thread: Re: undocumented limits on subprocesses?
  • Next by thread: Re: TransformedDistribution -- odd problem