# Best notation for probability density function?

$X$ is a continuous random variable, $Y$ is a discrete one. My goal is to find notation that minimizes notational abuse and maximizes consistency with all of probability theory.

Q1: What is the best way to write the conditional PDF function of $X$ that is conditioned on outcome of $Y$?

Below is a list of examples, but you can suggest others.

Example 1: $$f_{X|Y=y}(x)$$

Example 2: $$f_{X|Y}(x|y)$$

Example 3: $$f_{X}(x|Y=y)$$

Example 4: $$f(X=x|Y=y)$$

Q2: Additionally, what is the best notation for the joint PDF? Below are examples, but feel free to propose others:

Example 1: $$f_{X,Y}(x,y)$$

Example 2: $$f(X=x,Y=y)$$

Regardless which notation you use, remember that there will always be a trade-off between being concise and comprehensive.

My best way for the Q1 is:

$$f(x\mid y),$$

and for Q2 is

$$f(x, y).$$

I clearly chose to be succinct over comprehensive. It has advantages, but also disadvantages. I've read several books that directly or indirectly use random variables and stochastic processes, and their notation varies significantly depending on context and author preference. In addition, the author's area of knowledge also influences the adopted notation. That is, just by looking at the notation you can already have an idea whether the author is a Physicist, Mathematician, Engineer, Statistician, etc... I am an Electronics Engineer, and I usually read books about statistical signal processing and machine learning, so I obviously have my bias.

Some authors prefer to make a visual distinction between random and nonrandom variables. Papoulis, for instance, denotes random variables as bold letters, whereas an outcome of a given random event as its nonbold version. Leon Garcia, on the other hand, uses uppercase and lowercase to denote random and nonrandom variables, respectively. Note that these books teach the fundamentals of probability, random variables and stochastic processes. Normally, these notations is only adopted in this context.

• Advantage: It makes a clear distinction between random and nonrandom variables. It might be useful if you need to give a visual difference between a random variable and a numerical outcome associated to this random experiment. So, $$f_X(x_0)$$ denotes the PDF when random variable $$X$$ assume the value $$x_0$$.
• Disadvantage: This notation can interfere with the understanding of other terms, for example, if you use lowercase bold letters to denote vectors and uppercase bold letters to denote matrices.
• In my case: I do not make this distinction. That is, random and nonrandom variables has the same notation. That is bearable for me since most of the my variables are inherently random. On the other hand, I gain the freedom of denoting unambiguously a vector as $$\mathbf{x}$$ and a matrix as $$\mathbf{A}$$. When I need to denote the PDF of a random variable evaluated at a certain value, I use the evaluation bar notation, that is, $$\left.f(\mathbf{x}, \mathbf{y})\right|_{\mathbf{x}=\mathbf{a}, \mathbf{y}=\mathbf{b}}$$ or $$f(\mathbf{x}=\mathbf{a}, \mathbf{y}=\mathbf{b}).$$

Similarly, for conditional PDF's: $$\left.f(\mathbf{x} \mid \mathbf{y})\right|_{\mathbf{x}=\mathbf{a}, \mathbf{y}=\mathbf{b}}$$ or $$f(\mathbf{x}=\mathbf{a} \mid \mathbf{y}=\mathbf{b})$$

where $$\mathbf{x}$$ and $$\mathbf{y}$$ are random vectors, and $$\mathbf{a}$$ and $$\mathbf{b}$$ are constant vectors. You can find the same notation in some books of adaptive filters theory. I personally find the evaluation bar more elegant, check this out (if this writing were mine, I would omit the subscript):