Socrates' statement means that he preferred to die rather than live under the rules and conditions of others, and not be able to investigate.
The Greek philosopher said this expression after he was sentenced to death. Actually, he was forced to choose between death and exile. He selected to die because he considered that living without being permitted to do research was not worthy.