Skip to content
Advertisement

Pandas – iloc – comparing value to the cell below

For the following table:

enter image description here

Using Pandas – I would like achieve the desired_output column, that is TRUE when the value below the current cell i different – otherwise FALSE.

I have tried the following code – but error occurs.

JavaScript

Advertisement

Answer

JavaScript
User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement