Miller 5.2.0 已发布,Miller 是一个类似 sed、awk、cut、join 和 sort 工具,用来处理基于命名索引的数据,如 CSV、TSV 和 tabular JSON 。
该版本包括功能、文档上的改进,并修复了当使用 --c2j 等指定 I / O 格式时,CRLF line-endings 没有被正确的自动检测的问题,以及整数除以零导致的致命运行时异常问题。
下载地址:
效果示例:
before
county,tiv_2011,tiv_2012,line,construction SEMINOLE,22890.55,20848.71,Residential,Wood MIAMI DADE,1158674.85,1076001.08,Residential,Masonry PALM BEACH,1174081.5,1856589.17,Residential,Masonry MIAMI DADE,2850980.31,2650932.72,Commercial,Reinforced Masonry HIGHLANDS,23006.41,19757.91,Residential,Wood HIGHLANDS,49155.16,47362.96,Residential,Wood DUVAL,1731888.18,2785551.63,Residential,Masonry ST. JOHNS,29589.12,35207.53,Residential,Wood
after
$ mlr --icsv --opprint --barred \ put '$tiv_delta = $tiv_2012 - $tiv_2011; unset $tiv_2011, $tiv_2012' \ then sort -nr tiv_delta flins.csv +------------+-------------+----------------+ | county | line | tiv_delta | +------------+-------------+----------------+ | Duval | Residential | 1053663.450000 | | Palm Beach | Residential | 682507.670000 | | St. Johns | Residential | 5618.410000 | | Highlands | Residential | -1792.200000 | | Seminole | Residential | -2041.840000 | | Highlands | Residential | -3248.500000 | | Miami Dade | Residential | -82673.770000 | | Miami Dade | Commercial | -200047.590000 | +------------+-------------+----------------+
>>>【评论有礼】6月6日-30日评论每日更新的“新闻资讯和软件更新资讯”,评论点赞数超过 20 的可登上每周更新的“源资讯”和“软件周刊”两大栏目,点赞数超过 50 的还将获得 5 活跃积分奖励和开源中国定制好礼。详情
暂无更多评论