# Generate binary classification data in python?

Is there a simple way to generate binary classification data in python? I'd like to specify $$X$$ input parameter, $$[x_1,...,x_n]$$, and generate a dataset such that the (overall) McFadden's pseudo $$R^2$$ is equal to some parameter. I am struggling to find a package/library that meets this task.

Edit: by input parameter, I mean a single number. For example, 2. I want to be able to generate a dataset with 2 independent variables, X, and 1 dependent variable y, which is appropriate for logistic regression (provided a reasonably high pseudo R)

• Could you explain the meaning of these input "parameters"? What do they represent? What is your model? – whuber Sep 16 '20 at 20:56