使用 csvkit 打印列名
在 csvkit 中有多种方式可以预览数据(例如 csvlook、csvstat 等)。不过,如果您只想确认数据中各列的位置和名称,直接打印一行列名会更简单。请为数据文件 Spotify_MusicAttributes.csv 打印列名。
本练习是课程的一部分
Shell 中的数据处理
练习说明
- 使用
csvkit命令在控制台打印数据文件Spotify_MusicAttributes.csv的列名列表。
交互式实操练习
通过完成这段示例代码来试试这个练习。
# Check to confirm name and location of data file
ls
# Print a list of column headers in data file
___ ___ Spotify_MusicAttributes.csv