A complex of macromolecules found in cells, consisting of DNA, protein and RNA. The primary functions of chromatin are 1) to package DNA into a smaller volume to fit in the cell, 2) to reinforce the DNA macromolecule to allow mitosis, 3) to prevent DNA damage, and 4) to control gene expression and DNA replication.