BayesNets.jl icon indicating copy to clipboard operation
BayesNets.jl copied to clipboard

StaticCPD is confusing

Open tawheeler opened this issue 8 years ago • 3 comments

It seems like StaticCPD is confusing users.

A StaticCPD is just a CPD which always returns the same distribution, no matter what the parent values are. I did not want to call it ParentlessCPD because it can technically have parents, they just don't do anything.

Some possible ways to rename it are IndependentCPD or ParentAgnosticCPD. Neither of these sound great.

Does anyone have a better name?

tawheeler avatar Dec 09 '16 09:12 tawheeler

I was confused by this, but I'm having trouble thinking of a better name. Maybe just more documentation?

mykelk avatar Dec 09 '16 22:12 mykelk

Is a StaticCPD just a cumulative distribution function that takes in more than one real-valued random variable X, or a distribution function of more than one X? I don't understand why there should be a function just for this case, instead of making just one general CDF that allows the user to include whatever X it wants, type child, type parent, or both.

On a separate note, thanks for all the help you've been giving me.

hpoit avatar Mar 20 '17 16:03 hpoit

It makes sense to think of this a ConstantCPD because a constant functions is an f(x) = k and here we have a CPD p(Y|X) = p(Y). I know it has been over 3 years since this issue was opened so this might be moot at this point.

jpfairbanks avatar Feb 24 '20 16:02 jpfairbanks