OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

How can I get a column from my dataframe and then match it with next few consecutive alternate columns in same df in pandas? [closed]

  • Thread starter Thread starter Twinkle
  • Start date Start date
T

Twinkle

Guest
I am new to pandas and I've been given a dataframe having millions of rows. I want to compare a particular column with further alternate consecutive columns and compare the values whether it lies between those two alternate columns in the same dataframe.

I'm having difficulty in accessing those alternate columns- if the values doesn't lies between the first two alternate columns then next column should be checked.

I tried looping it through but couldn't get how to get accessing values from alternate columns
<p>I am new to pandas and I've been given a dataframe having millions of rows. I want to compare a particular column with further alternate consecutive columns and compare the values whether it lies between those two alternate columns in the same dataframe.</p>
<p>I'm having difficulty in accessing those alternate columns-
if the values doesn't lies between the first two alternate columns then next column should be checked.</p>
<p>I tried looping it through but couldn't get how to get accessing values from alternate columns</p>
 

Latest posts

J
Replies
0
Views
1
jbowerbir
J
Top