MulaiMulai sekarang secara gratis

Stacking files with csvkit

SpotifyData_PopularityRank6.csv and SpotifyData_PopularityRank7.csv have the same file format, column order, and overall data schema. However, one file contains information for songs ranked #6, and the other contains information for songs ranked #7. Combine the two files together into one unified file by stacking them.

Latihan ini adalah bagian dari kursus

Data Processing in Shell

Lihat Kursus

Petunjuk latihan

  • Stack SpotifyData_PopularityRank6.csv and SpotifyData_PopularityRank7.csv together. Re-direct the output of this stacking and save as a new file called SpotifyPopularity.csv.

Latihan interaktif praktis

Cobalah latihan ini dengan menyelesaikan kode contoh berikut.

# Stack the two files and save results as a new file
___ SpotifyData_PopularityRank6.csv SpotifyData_PopularityRank7.csv ___ SpotifyPopularity.csv

# Preview the newly created file 
csvlook SpotifyPopularity.csv
Edit dan Jalankan Kode