Advertisements
Advertisements
प्रश्न
How is the difference between a DataFrame and 2-D array.
अंतर स्पष्ट करें
Advertisements
उत्तर
| Feature | DataFrame (Pandas) | 2-D Array (NumPy) |
| Definition | A DataFrame is a two-dimensional labelled data structure. | A 2-D array is a two-dimensional collection of elements arranged in rows and columns. |
| Data Type | Can store different data types in different columns. | Usually stores elements of the same data type. |
| Row & Column Labels | Has customisable row and column labels. | Uses only numeric indexes. |
| Operations | Supports data analysis, filtering, sorting, and grouping. | Mainly supports numerical and mathematical operations. |
| Library | A DataFrame uses the Pandas library. | A 2-D array uses the NumPy library. |
| Main Use | Used for data analysis and handling tabular data. | Used for numerical and scientific computations. |
shaalaa.com
क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
