简体   繁体   中英

Plot surface dividing 3d data by value

I have a 3d dataset, where each sample has 3 coordinates (x,y,z) and a value either 0 or 1. I want to plot a surface which divides the points with value 1 from the points with value 0. For example, let's say that all the points with x,y and z grater than zero have value 1, while all other points have value 0. But in my problem, I don't know the analytical expression that divides the two categories. What would the best way to draw such surface in Python?

You can use the SVC (Support Vector Classifier). It gives you the decision boudaries for the classed data. Scikit learn has an API for SVC - https://scikit-learn.org/stable/modules/generated/sklearn.svm.SVC.html#sklearn.svm.SVC

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM