Aug-23-2020, 06:02 PM
You say if
You are correct. But if the first line in two code series is false, I do not believe
the original programmer/analyst wanted the program to crash.
I believe she just wanted the next set of python code lines to be skipped. The code that counts the number of offensive players and where they are positioned.
If that is correct the program, should not crash. It should just skip the row and continue in the loop.
It does not do that. The program crashes. How to modify the code so that it executes what the programmer originally intended, not what is actually happening.
]You alluded to the fact the there might be a formatting problem in an earlier post. I think you are right. I just do not know how to fix.
I do not want to delete the whole row because it might contain information is the other cells that could make the prediction more accurate.o
Any help appreciated. Thanks in advance.
Respectfully,
ErnestTBass
if not pd.isna(row['personnel.offense']): personnel = row['personnel.offense'].split(',')If the first line is false then the second line is not executed.
You are correct. But if the first line in two code series is false, I do not believe
the original programmer/analyst wanted the program to crash.
I believe she just wanted the next set of python code lines to be skipped. The code that counts the number of offensive players and where they are positioned.
If that is correct the program, should not crash. It should just skip the row and continue in the loop.
It does not do that. The program crashes. How to modify the code so that it executes what the programmer originally intended, not what is actually happening.
]You alluded to the fact the there might be a formatting problem in an earlier post. I think you are right. I just do not know how to fix.
I do not want to delete the whole row because it might contain information is the other cells that could make the prediction more accurate.o
Any help appreciated. Thanks in advance.
Respectfully,
ErnestTBass