27

I am writing a big formula where a vertical line is needed. Instead of $\vline$ or $|$, does anyone know a way to draw this vertical line of desired length? The formula is something like

$$
E\Bigg[
F_{m-1}\Big( \text{some big contents} \Big) |\: \mathcal{F}_1
\Bigg]
$$

Thank you very much!

Caramdir
  • 89,023
  • 26
  • 255
  • 291
Anand
  • 3,696
  • 3
    For lots of examples and techniques for typesetting math, the mathmode documentation is very helpful. It should be part of your TeX distribution. – Alan Munn Jan 02 '11 at 18:53
  • Thanks Alan Munn, I guess what you mean is this one: http://www.tex.ac.uk/tex-archive/info/math/voss/mathmode/Mathmode.pdf It is very helpful.:-) – Anand Jan 02 '11 at 21:09

2 Answers2

39

Try enclosing your expression into \left. and \right\vert, as in

\left.\frac{\partial L}{\partial\bm{\beta}}\right\vert_{\hat\beta}=-2\bm{X'y}+2\bm{X'X\hat\beta}=0

which yields:

alt text

chl
  • 8,890
32

Well, if you are manually defining the size, as in the example you could just put a \Bigg| at the right place. Probably better would be using \left, \middle and \right.

By the way: You should prefer \[ and \] instead of double $$.

\[ E\left[ F_{m-1}\Big( \text{some big contents} \Big) \middle|\: \mathcal{F}_1 \right] \]