Advertisements
Advertisements
Question
Explain the importance of reshaping of data with an example.
Explain
Advertisements
Solution
Data reshaping is the process of changing the layout or structure of a dataset (altering its rows and columns) without changing the actual information it contains.
- Better Readability: It transforms raw, complex data into a clean layout that is easier for humans to analyse.
- Compatibility: It alters data formats to fit the strict layout requirements of plotting tools and machine learning models.
Example:
Converting a long list of daily sales transactions into a wide summary table where each product becomes its own column header [pydata.org]. This allows you to compare different item sales side-by-side on any given date instantly.
shaalaa.com
Is there an error in this question or solution?
