Maximum likelihood estimator for choice-based samples