I created a function called polar(X_relative , Y_relative , Z_relative)
that takes these 3 arguments as shown and the result are new arguments which are (azimuth_angle , tilt_angle)
.
I want to apply this function to a pandas dataframe where the function arguments are certain columns in the dataframe and would like to add the output arguments of the functions (azimuth_angle , tilt_angle)
as new coulmns in the dataframe where the function is calculated for each row.
dataframe columns: X , Y, Z , X_relative , Y_relative , Z_relative
dataframe coulmns I expect after applying the function: X , Y, Z , X_relative , Y_relative , Z_relative , azimuth_angle , tilt_angle