I have a data set in which i have diameters of lunar craters. I need to group them into different categories.(using python)
Column names in my data are ID, latitude, londitude, diameter and depth. Values seperated by space
For eg: there is a crater of 980m as diameter then it does into the class of craters whose diameter is less than 1 km (let us name that category as SET1) similarly there is a crater of diameter 40 km then it goes into the category of craters whose diameter is less than 50km but greater than 30km (let us name it as SETX). I need to create such categories and classify all these craters into them.
I also need to count the number of craters in each such categories. Also note there are almost 0.8 million craters in my data.
I need ideas or solution to how can I can solve the above problem.
0.8 million craters isn't that much.
Since I don't know your data format exactly, this isn't guaranteed to work out of the box, but the basic idea is to simply to read the data, bin it using
pd.cut, and to print value counts.