The test is ordered when a person requires an organ transplant, bone marrow transplant, or stem cell transplant to determine the compatibility between the donor and recipient. It is also ordered to identify the risk of autoimmune diseases such as celiac disease, rheumatoid arthritis, type 1 diabetes, and lupus.