# 8.1 concat: rows एकाखाली एक

Source: https://ravindrabagale.com/mr/datascience/ch08-combining-data/8-1-concat-stack-rows.html
Language: mr (Marathi with English technical terms)

September आणि October च्या सारख्या columns असलेल्या tables एकत्र करूया:

import pandas as pd

sep = pd.DataFrame({"order_id": ["BLK-A"], "city": ["Pune"], "amount": [100]})
oct_ = pd.DataFrame({"order_id": ["BLK-B"], "city": ["Nashik"], "amount": [200]})
all_orders = pd.concat([sep, oct_], ignore_index=True)
all_orders

Columns आणि grain सारखे असतील तर rows जोडण्यासाठी concat वापरा. Key वरून शेजारी नवीन माहिती जोडायची असेल तर merge वापरा.

रवींद्र बागले यांची tip

ignore_index=True मुळे output मध्ये नवीन सलग index मिळतो. तो business order_id चा पर्याय नाही.
