The sample data is as follows:
angle contain values from -60 to 60
| angle | distance |
|---|---|
| -60 | 3.95 |
| -60 | 3.95 |
| -60 | 6.95 |
| -60 | 8.95 |
| -60 | 8.95 |
| -55 | 2.38 |
| -55 | 3.38 |
The expected new data:
| angle_new | mean_distance | min_distance | max_distance |
|---|---|---|---|
| -60 | 6.55 | 3.95 | 8.95 |
| -55 | 2.88 | 2.38 | 3.38 |
How to make this expected output data from sample data with pandas in python?