On what basic pd.cut functuon splits the dataset?

X_train.apply(pd.cut,bins=2,labels=[0,1])

Let’s suppose we have a data, and we apply pd.cut function, and pass bins=3. This will partition the data into 3 partitions, of size “(Max-Min)/bins”. And further on convert the data in these partitions to categorical values provided in the label.