I have the following dataframe.
SEC VORDEN_PREVENT1 VORDEN_PREVENT2 VORDEN_PREVENT3 VORDEN_PREVENT4 VORDEN_PREVENT5
2484628 1500 1328 2761 3003 2803
2491884 1500 1500 1169 2813 1328
2521158 1500 2813 1328 2761 3003
2548370 1500 1257 2595 1187 1837
2580994 1500 5057 2624 2940 2731
2670164 1500 1874 1218 2791 2892
In this dataframe I have as VORDEN_PREVENT*
the number of cars sold every day, for example VORDEN_PREVENT1
means that I sold this day 1500 cars, what I want is to return the columns from the rows that produces a purchase of for example 3000 cars.
For that example, should be 1500 from VORDEN_PREVENT1
, 1328 from VORDEN_PREVENT2
and 172 from VORDEN_PREVENT3
, which is the difference from 2761 and the sum from VORDEN_PREVENT1
and VORDEN_PREVENT2
.
I don't know how to obtain this row and column data and to get the difference properly, to obtain my data correctly.