DEV Community

Mustafa  Çam
Mustafa Çam

Posted on

1

iloc function in python

import pandas as pd

# Örnek bir veri çerçevesi oluşturalım
df = pd.DataFrame({'A': [1, 2, 3], 'B': [4, 5, 6], 'C': [7, 8, 9]})

# select the first line
ilk_satir = df.iloc[0]
print(ilk_satir)
Enter fullscreen mode Exit fullscreen mode
çıktı =>

A    1
B    4
C    7
Enter fullscreen mode Exit fullscreen mode

yani burda iloc foksiyonumuz veri çerçevesindeki elemanlar üzerinde işlem gerçekleştiriyor pandas kütüphanemizi kullanarak

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay