Disentangling multiple emitting components in molecular observations with nonnegative matrix factorization